Re: [RFC 1/2] printk: Add kernel parameter: mute_console

From: Guenter Roeck
Date: Fri Oct 23 2020 - 10:52:17 EST


On 10/23/20 4:49 AM, Petr Mladek wrote:
> On Thu 2020-10-22 16:59:15, John Ogness wrote:
>> On 2020-10-22, Guenter Roeck <linux@xxxxxxxxxxxx> wrote:
>>> The whole point of the exercise is to disable all consoles, including
>>> default ones which are not explicitly specified on the command line.
>>
>> In that case I think specifying something like:
>>
>> console=null
>>
>> makes that most sense. I think implementing a "null console" driver
>> would be quite simple. Then there would be no need for special handling
>> in the printk subsystem.
>
> Heh, it actually already exists and has been created for exactly this
> purpose, see the commit 3117ff13f104e98b05b6 ("tty: Add NULL TTY
> driver").
>

Ok with me to use that, as long as we add code that maps console=
and console=null to console=ttynull.

Guenter

> Regarding the interface:
>
> + console=null or console= is OK when people do not want consoles
> at all
>
> + mute_console (or another extra parameter) would be needed if
> people wanted to have login console.
>
> It is true that nobody asked for the login support. So, the null
> console should be enough for now.
>
> Best Regards,
> Petr
>