Received: by 2002:a25:1104:0:0:0:0:0 with SMTP id 4csp428781ybr; Fri, 22 May 2020 09:55:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzpgR+d9aCLTbaT63+O57ZtTIjPrIUB/qEP4xn/hcp2LN8K7VRgQ0+7FYq97HnyW+xd9nJl X-Received: by 2002:a17:906:eda3:: with SMTP id sa3mr9521061ejb.253.1590166538997; Fri, 22 May 2020 09:55:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590166538; cv=none; d=google.com; s=arc-20160816; b=FGpYzL9djVYKXVYdYKnHdjC3Qzqwcg0yblL5i6nxFnFSMVn7coOAFGh2DPZvWXbbHs Vecbr5v1R4pUiH30EaeDrc9HWfpTZE/tMIaJsoUWaq9TmEQxZznNJWp4XiU3aNz6BGdG mnhOXzVYkya1lumoEa+fDjoaBbV2cnL5SJz0yGM8J7g9rZecAHyg35iARZz8XDQpGOoL 3IVtjY54yeZYHRcAIHTQG/V0mSabJgVkdgdaOYDajt7MGvHgfa4iTTHOXjlGWv+4Gwlx 5VFubo1ozhXyDoKeP39LH4WihaftUyPOBTKW5n52JVgY1PyGwW36HcMxMQH+PLudxk3u dmiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=oIu7auu+QFxwZSN3HPPW2sQJgDPqA0MA1ee5NGcgIvY=; b=NWI32+MKxENCwSIXiEr5vyMGkGqdJv5OqVeqzljz2ZeyKml14WV4L0y4nGXFN354eX NU+EHB0h3T04IViZZm8+PuzaacYQFVx1qIsqJp+43XMgUbRhHTKdu96t6GdEzF58fi1B vgneVc2HBktZTMbOhGt+YAy/46BHLrtQaClfpz4U1H7rh/HDN3GkqvkEZWzjwrRPuHF3 /SlV7dLWiJOB2o2zniOajobpQCfRSfoL8w9mWareDbnQ753PzMXwQd7Q713b+9hSW3CN d1mnse2Cp0OhwHmaUQiJwPqzY0lCTyEu9Phqp7eu70SDz+bEK1l7tTK3XdS6zlYrgC9k auQQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i60si4915991edd.0.2020.05.22.09.55.16; Fri, 22 May 2020 09:55:38 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730739AbgEVQvY (ORCPT + 99 others); Fri, 22 May 2020 12:51:24 -0400 Received: from mx2.suse.de ([195.135.220.15]:51736 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730487AbgEVQvY (ORCPT ); Fri, 22 May 2020 12:51:24 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 9E6B6ABE3; Fri, 22 May 2020 16:51:24 +0000 (UTC) Date: Fri, 22 May 2020 18:51:20 +0200 From: Petr Mladek To: Kees Cook Cc: Pavel Tatashin , Anton Vorontsov , Colin Cross , Tony Luck , Jonathan Corbet , Benson Leung , Rob Herring , Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , Enric Balletbo i Serra , Sergey Senozhatsky , Steven Rostedt , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH v4 2/6] printk: honor the max_reason field in kmsg_dumper Message-ID: <20200522165120.GL3464@linux-b0ei> References: <20200515184434.8470-1-keescook@chromium.org> <20200515184434.8470-3-keescook@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200515184434.8470-3-keescook@chromium.org> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri 2020-05-15 11:44:30, Kees Cook wrote: > From: Pavel Tatashin > > kmsg_dump() allows to dump kmesg buffer for various system events: oops, > panic, reboot, etc. It provides an interface to register a callback call > for clients, and in that callback interface there is a field "max_reason" > which gets ignored unless always_kmsg_dump is passed as kernel parameter. Strictly speaking, this is not fully true. "max_reason" field is not ignored when set to KMSG_DUMP_PANIC even when always_kmsg_dump was not set. It should be something like: "which gets ignored for reason higher than KMSG_DUMP_OOPS unless always_kmsg_dump is passed as kernel parameter". Heh, I wonder if anyone will be able to parse this ;-) Otherwise, it looks good to me. With the updated commit message: Reviewed-by: Petr Mladek Best Regards, Petr