lkml.org 
[lkml]   [2020]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [PATCH] printk: Add loglevel for "do not print to consoles".
    From
    Date
    On 2020/04/25 1:21, Steven Rostedt wrote:
    > On Sat, 25 Apr 2020 01:10:15 +0900
    > Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp> wrote:
    >
    >> KERN_NO_CONSOLES is a mechanism for implementing user decided policy. As long as
    >> userspace can control whether to use KERN_NO_CONSOLES (e.g. sysctl), there should
    >> be no problem with adding KERN_NO_CONSOLES (i.e. this patch) to the kernel side.
    >
    > How would you define what gets "KERN_NO_CONSOLES"? Is it going to be a
    > sysctl switch?

    Yes. See
    https://lkml.kernel.org/r/c95dfafb-fe9c-19d7-8d42-bcd7d0946867@i-love.sakura.ne.jp .

    >
    > Also, how does one control the log level of prints with KERN_NO_CONSOLES?

    I couldn't understand the question.

    KERN_NO_CONSOLES is just a flag for not to call call_console_drivers().
    Messages printed with printk(KERN_$LOGLEVEL KERN_NO_CONSOLES ...) will be
    read by userspace syslog daemon and be filtered based on KERN_$LOGLEVEL.

    \
     
     \ /
      Last update: 2020-04-24 18:35    [W:3.955 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site