Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp4952531imm; Tue, 19 Jun 2018 02:34:28 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKqEwnIxkgs+ZX3U9ajAeoEe5XP4wqZhMXAM5VfOQtaUje8wvrF7iDSW900E6/QHEJkrH2m X-Received: by 2002:a17:902:4545:: with SMTP id m63-v6mr18253186pld.268.1529400868571; Tue, 19 Jun 2018 02:34:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529400868; cv=none; d=google.com; s=arc-20160816; b=LyENbalSZATKrjQcPcWSx0qMEGx4YfYG9IlcYnEB35GfPROYBiJK8RqPKl4SfJH4s+ 8o0qCDEl2jD94YoAhFH/wzFOnXbEORluWXTMqWUL+C+XLadz/so+ecbOFypAKUClBS3A gvkPWJX3Cze/auryr+CbxXHyFO/aZVd0g27dEx+ExHSFvNdad8zZZfjgwabd0drAZxYK 720DAVDJBXkKuKk55VDyKP+VQRHA5DV1QpCiPZRi5ppUCdEjJMJOd9vF6rSBt4y3rn3K sUGq9ogyBOsLGQ3PLukmKAQUjhjl8I0gWJKg4WGF4Ieo5i+pzDTARQh27JWMtm5/um/3 iu0w== 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:arc-authentication-results; bh=MSD6rLQKinGK8bgrG82aUp60zan5eutaG1DRv6t82R8=; b=mgycsV+56nFw3k1tPsJz+qSph2bHdXAkeZlQmqZVpotyZQLZArN3J33S1PktCSwHGx z3hpo6NW9GVd5uujLm2iNrxrupkjiG8rRhbvRMB5X4QfpEo4U3ZBqJpDg6/Rkbl7EHW+ TI1zIWuKTr4drg2F0KDBjlj0CMFXz5nkgN6C5PySxtfxR0atSBsKxYOJlKyIjSXumOAv 7E/TV404cpXCXR/72j5MUvEtNSWA9r5yPricZBY7VbU0Op8PaAYazebGL5ZwrK8QiP5M xDDz/vP5Q+aIyxNXjQC3rw+jNg1zmAzqQsLSeGXWQM+LF72g2kd5yE9Y+2UYPZROCx/H r5KA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e7-v6si18424392plj.311.2018.06.19.02.34.15; Tue, 19 Jun 2018 02:34:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757022AbeFSJcw (ORCPT + 99 others); Tue, 19 Jun 2018 05:32:52 -0400 Received: from mx2.suse.de ([195.135.220.15]:43974 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756976AbeFSJct (ORCPT ); Tue, 19 Jun 2018 05:32:49 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext-too.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 96FEAAE54; Tue, 19 Jun 2018 09:32:48 +0000 (UTC) Date: Tue, 19 Jun 2018 11:32:44 +0200 From: Petr Mladek To: Sergey Senozhatsky Cc: Maninder Singh , sergey.senozhatsky@gmail.com, rostedt@goodmis.org, linux-kernel@vger.kernel.org, a.sahrawat@samsung.com, pankaj.m@samsung.com, v.narang@samsung.com Subject: Re: [PATCH v2] printk: make sure to print log on console. Message-ID: <20180619093244.ehj34uhpnpv6447f@pathway.suse.cz> References: <20180601090029epcas5p3cc93d4bfbebb3199f0a2684058da7e26~z-a_jkmrI2993329933epcas5p3q@epcas5p3.samsung.com> <20180618061550.GA27996@jagdpanzerIV> <20180618062306.GA29683@jagdpanzerIV> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180618062306.GA29683@jagdpanzerIV> User-Agent: NeoMutt/20170421 (1.8.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon 2018-06-18 15:23:06, Sergey Senozhatsky wrote: > On (06/18/18 15:15), Sergey Senozhatsky wrote: > > > > On (06/01/18 14:26), Maninder Singh wrote: > > > > > > Signed-off-by: Vaneet Narang > > > Signed-off-by: Maninder Singh > > > > Reviewed-by: Sergey Senozhatsky > > OK, we probably need v3 after all. > > I think this > > - if (suppress_message_printing(msg->level)) { > + if (msg->flags & LOG_NOCONS) { > > must be changed to > > - if (suppress_message_printing(msg->level)) { > + if (!ignore_loglevel && (msg->flags & LOG_NOCONS)) { > > > `ignore_loglevel' is a module param and can change any time via > /sys/module/printk/parameters/ignore_loglevel > we need to respect its value. I would prefer to keep the patch as is. I see it the following way. Also console_loglevel can be changed anytime by /proc/sys/kernel/printk. The patch basically moves the decision about the message visibility from console_unlock() to vprintk_emit(). The logic is easier when all aspects are handled in a single location and only once. Best Regards, Petr