Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp297279pxj; Thu, 17 Jun 2021 03:01:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx7yNT1PcJOYvmP+Xvg8jQ5gj+gTThLxX+9dNO9n6X7TW/40MrIV1z43DTRAc2hLWB9Qj/r X-Received: by 2002:a05:6e02:5ce:: with SMTP id l14mr3121984ils.94.1623924066723; Thu, 17 Jun 2021 03:01:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623924066; cv=none; d=google.com; s=arc-20160816; b=qq+gvDTj836DAtZPMDNIb+rd5ZkOMZkDgEyWc9K8TNh8AM4xa6wXXLJetQV49n9HNf vmwCLq3uf7LnKVL9+7MoEN6OgB2VNyiRTzupWDAFhkkMHt2qt6x2XA4wR1svwrU/a2LM 7bVTZ4Gu3GFm5NInKHw1HXrSfymnHIwn4NW9uinrgTpJI96APnSzRP3RZ96fl6uhYeci BvuYHSZxtEBNUaEulYs4vbvHetUgzLs4hnQCHzjbGKFFlL8z2DayjW+7Oiak8y/c2tEY ZJfyZFfU3r873hG7Pmhch/8FB1s7/MAg8kG9Amduc5myLk5UJKg8YKvT9LNVoNG1ftKJ ERNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=eFbML/Oep3LvS/U9xwYfXnNl7AEm54HwbIMYPmjktMU=; b=wUdqfa8yt26qPDVt1TMsH+baT72HF9JTX9lTGjl1f4TEE8Bn+KMEUEYODD3vtThIAS SpxBjvC6nLkzX4CNk7bD2n0Sj/YTx/5vTMWZc2cJ46gjFxfg13+vh27XREDsZFI2UpIx qGFm8cSwrWPhtXCLWA0VIuYobQ380b8QLUbQ9op46ZH+E0Dj/g4CvkChuRNSpm0LkFbI rw9f9V+dkeJo31JbODfWBsLfFAtkwP7dy5z18Rr0fbqEABM/sv4e9+yesMKjf/fccdLe pYyFr5tkWq4zxREELBfdKL1hyl0oATJhqGB+fb6OufVHHBcA9XnmlWz/ey0Aez088S88 bNAg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=qgex8SLu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i17si4978147iog.70.2021.06.17.03.00.54; Thu, 17 Jun 2021 03:01:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=qgex8SLu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231751AbhFQJp5 (ORCPT + 99 others); Thu, 17 Jun 2021 05:45:57 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:47324 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230238AbhFQJp5 (ORCPT ); Thu, 17 Jun 2021 05:45:57 -0400 Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 019F81FDBF; Thu, 17 Jun 2021 09:43:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1623923029; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=eFbML/Oep3LvS/U9xwYfXnNl7AEm54HwbIMYPmjktMU=; b=qgex8SLuV2jdeAzWQ3/MICZvm1vE8GxXB5QwJQEVzOhJzsO/ruy4iaUF54L6P4Ek9wGmt2 k4TkHBGMQUAx3lzT0vHa2LOeV/VNYfF8V1kNH2fZaQl3VVBR83Y+q6S8/5PEH5m/aXAqA8 yAEiCuSjlRObje6EszPee8xYk0iskH8= Received: from suse.cz (unknown [10.100.224.162]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id DA120A3BBB; Thu, 17 Jun 2021 09:43:48 +0000 (UTC) Date: Thu, 17 Jun 2021 11:43:48 +0200 From: Petr Mladek To: Chris Down Cc: linux-kernel@vger.kernel.org, Jessica Yu , Sergey Senozhatsky , John Ogness , Steven Rostedt , Greg Kroah-Hartman , Johannes Weiner , Kees Cook , Andy Shevchenko , Rasmus Villemoes , kernel-team@fb.com Subject: Re: [PATCH v7 4/5] printk: Userspace format indexing support Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 2021-06-15 17:52:53, Chris Down wrote: > We have a number of systems industry-wide that have a subset of their > functionality that works as follows: > > 1. Receive a message from local kmsg, serial console, or netconsole; > 2. Apply a set of rules to classify the message; > 3. Do something based on this classification (like scheduling a > remediation for the machine), rinse, and repeat. > > This provides a solution to the issue of silently changed or deleted > printks: we record pointers to all printk format strings known at > compile time into a new .printk_index section, both in vmlinux and > modules. At runtime, this can then be iterated by looking at > /printk/index/, which emits the following format, both > readable by humans and able to be parsed by machines: > > $ head -1 vmlinux; shuf -n 5 vmlinux > # filename:line function "format" > <5> block/blk-settings.c:661 disk_stack_limits "%s: Warning: Device %s is misaligned\n" > <4> kernel/trace/trace.c:8296 trace_create_file "Could not create tracefs '%s' entry\n" > <6> arch/x86/kernel/hpet.c:144 _hpet_print_config "hpet: %s(%d):\n" > <6> init/do_mounts.c:605 prepare_namespace "Waiting for root device %s...\n" > <6> drivers/acpi/osl.c:1410 acpi_no_auto_serialize_setup "ACPI: auto-serialization disabled\n" > > > Signed-off-by: Chris Down This version looks fine to me: Reviewed-by: Petr Mladek Tested-by: Petr Mladek Best Regards, Petr