[PATCH v2] powerpc: Support CMDLINE_EXTEND

Christophe Leroy christophe.leroy at c-s.fr
Fri Aug 2 14:39:00 AEST 2019



Le 02/08/2019 à 00:32, Chris Packham a écrit :
> On Thu, 2019-08-01 at 08:14 +0200, Christophe Leroy wrote:
>>
>> Le 01/08/2019 à 04:12, Chris Packham a écrit :
>>>
>>> Bring powerpc in line with other architectures that support
>>> extending or
>>> overriding the bootloader provided command line.
>>>
>>> The current behaviour is most like CMDLINE_FROM_BOOTLOADER where
>>> the
>>> bootloader command line is preferred but the kernel config can
>>> provide a
>>> fallback so CMDLINE_FROM_BOOTLOADER is the default. CMDLINE_EXTEND
>>> can
>>> be used to append the CMDLINE from the kernel config to the one
>>> provided
>>> by the bootloader.
>>>
>>> Signed-off-by: Chris Packham <chris.packham at alliedtelesis.co.nz>
>>> ---
>>> While I'm at it does anyone think it's worth getting rid of the
>>> default CMDLINE
>>> value if CMDLINE_BOOL and maybe CMDLINE_BOOL? Every defconfig in
>>> the kernel
>>> that sets CMDLINE_BOOL=y also sets CMDLINE to something other than
>>> "console=ttyS0,9600 console=tty0 root=/dev/sda2". Removing
>>> CMDLINE_BOOL and
>>> unconditionally setting the default value of CMDLINE to "" would
>>> clean up the
>>> Kconfig even more.
>> Note
>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/co
>> mmit/?id=cbe46bd4f5104552b612505b73d366f66efc2341
>> which is already a step forward.
>>
>> I guess that default is for users selecting this option manually to
>> get
>> a first sensitive CMDLINE. But is it really worth it ?
>>
> 
> I'm not even sure if it is working as intended right now. Even without
> my changes if I use menuconfig and select CMDLINE_BOOL I end up with
> CONFIG_CMDLINE="" in the resulting .config.

I guess if the CONFIG_CMDLINE doesn't exist yet, it will get the default 
value. But if it is already there allthough empty, it will remain empty.
So yes I guess you could just drop it for this reason and the other 
reasons you said.

Christophe



More information about the Linuxppc-dev mailing list