lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20210325200357.GN109100@zorba>
Date:   Thu, 25 Mar 2021 13:03:57 -0700
From:   Daniel Walker <danielwa@...co.com>
To:     Christophe Leroy <christophe.leroy@...roup.eu>
Cc:     Will Deacon <will@...nel.org>, Rob Herring <robh@...nel.org>,
        Daniel Gimpelevich <daniel@...pelevich.san-francisco.ca.us>,
        Andrew Morton <akpm@...ux-foundation.org>, x86@...nel.org,
        linux-mips@...r.kernel.org, linuxppc-dev@...ts.ozlabs.org,
        xe-linux-external@...co.com, Michael Ellerman <mpe@...erman.id.au>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>,
        Paul Mackerras <paulus@...ba.org>,
        Ruslan Ruslichenko <rruslich@...co.com>,
        Ruslan Bilovol <rbilovol@...co.com>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 4/7] CMDLINE: powerpc: convert to generic builtin
 command line

On Wed, Mar 24, 2021 at 04:31:35PM +0100, Christophe Leroy wrote:
> 
> 
> Le 09/03/2021 à 22:40, Daniel Walker a écrit :
> > On Tue, Mar 09, 2021 at 08:56:47AM +0100, Christophe Leroy wrote:
> > > 
> > > 
> > > Le 09/03/2021 à 01:02, Daniel Walker a écrit :
> > > > This updates the powerpc code to use the CONFIG_GENERIC_CMDLINE
> > > > option.
> > > > 
> > > > Cc: xe-linux-external@...co.com
> > > > Signed-off-by: Ruslan Ruslichenko <rruslich@...co.com>
> > > > Signed-off-by: Ruslan Bilovol <rbilovol@...co.com>
> > > > Signed-off-by: Daniel Walker <danielwa@...co.com>
> > > > ---
> > > >    arch/powerpc/Kconfig            | 37 +--------------------------------
> > > >    arch/powerpc/kernel/prom.c      |  1 +
> > > >    arch/powerpc/kernel/prom_init.c | 35 ++++++++++++++++++-------------
> > > >    3 files changed, 23 insertions(+), 50 deletions(-)
> > > > 
> > > > diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
> > > > index 107bb4319e0e..276b06d5c961 100644
> > > > --- a/arch/powerpc/Kconfig
> > > > +++ b/arch/powerpc/Kconfig
> > > > @@ -167,6 +167,7 @@ config PPC
> > > >    	select EDAC_SUPPORT
> > > >    	select GENERIC_ATOMIC64			if PPC32
> > > >    	select GENERIC_CLOCKEVENTS_BROADCAST	if SMP
> > > > +	select GENERIC_CMDLINE
> > > >    	select GENERIC_CMOS_UPDATE
> > > >    	select GENERIC_CPU_AUTOPROBE
> > > >    	select GENERIC_CPU_VULNERABILITIES	if PPC_BARRIER_NOSPEC
> > > > @@ -906,42 +907,6 @@ config PPC_DENORMALISATION
> > > >    	  Add support for handling denormalisation of single precision
> > > >    	  values.  Useful for bare metal only.  If unsure say Y here.
> > > > -config CMDLINE
> > > > -	string "Initial kernel command string"
> > > > -	default ""
> > > > -	help
> > > > -	  On some platforms, there is currently no way for the boot loader to
> > > > -	  pass arguments to the kernel. For these platforms, you can supply
> > > > -	  some command-line options at build time by entering them here.  In
> > > > -	  most cases you will need to specify the root device here.
> > > > -
> > > > -choice
> > > > -	prompt "Kernel command line type" if CMDLINE != ""
> > > > -	default CMDLINE_FROM_BOOTLOADER
> > > > -
> > > > -config CMDLINE_FROM_BOOTLOADER
> > > > -	bool "Use bootloader kernel arguments if available"
> > > > -	help
> > > > -	  Uses the command-line options passed by the boot loader. If
> > > > -	  the boot loader doesn't provide any, the default kernel command
> > > > -	  string provided in CMDLINE will be used.
> 
> I can't see how the above is supported in the generic builtin.
> 
> Taking into account that it is the default on powerpc, I'm having hardtime with that.

Hmm, so this ignores the built in changes. You just don't enable it, or you
don't add PREPEND or APPEND.

> Any feedback on the proposed changes I made on the 13th ? I know it is
> partly buggy but that was more for the principle. I can make clean working
> patch if it helps.


The reason I added it into the function parameters is because I can get free
type checking on the functions. If you use macro's then you don't know if the
function is compatible.

Daniel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ