Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp746558pxf; Thu, 25 Mar 2021 13:07:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzXXVjr13yD9CBUgfkOFRhlbB4x65n24aqS0tvAtm4o68P0UOmFHV8iGRa/spmDnmtCQUOc X-Received: by 2002:a17:906:6d8e:: with SMTP id h14mr11458993ejt.410.1616702849246; Thu, 25 Mar 2021 13:07:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616702849; cv=none; d=google.com; s=arc-20160816; b=RdqPZCdwzvV4Zm2/yx+fCHJT08RUgIYO6/DSxjvB/x0/jyACD84IPvi7pLAVfxH3rR kc3zg3yfY/OvVpLiT02gRBcvGz5/T0b6QZOvlLjvPxdmtc3R6FepmaXGLWxACk+of4o9 t4RIEO8Nn+VhEHesiD1bg7VjcGp5a0A8rwaZ0ywQiCtza2kL8cfoLDyawlMKLMOZEhAS cQpqJxOtu+xdH/FH9UKRe6VOhjkfwnIR45u2gO82LEqhjxIn7DqH3uVIWop5JxCvzTso 0lhMWJO1Q9kfJ7bLO1i7GUEgqIlHKzpl4fPmzxyMN1lMYwIvNH3aRFNn7zzSL4kNWT1R jy3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=WY2gjCyz0Ik/kpQDckMPbX/rhjgxQdQwh/Y/oNuhyBk=; b=UxBI3EXKmGlR89Mis8iKsvmYU8oC5cHUwasREZxdm5WwTnGkXKQ6HWl1zHzvOY10P9 qwX9XmMZIMWJmILMWrYNAJDJN0qUl4IWQHcO5HyYs+U8ZJvzwssbyU8bnXQtsPtt2blP MJIm33oKuaNpdX13LIUxOhd+YzyNaTC9gSo1WPv0lUrJV/Q6NEpP/7RmuFazX/uvX3kF JiMQbcE40oVFd/NVC+PPLRlqGuirjg+rRs0gBvkjW1IZM90YWwWZJNoszW34iQEwDVM3 gU+Z34b56kxWGKgzbxhF1dcZCBs0VBS9Bt8+GhpKlBKfKqcaYEScR9J4dSfOivE6EsmY +AtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=HPYH0hSt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=cisco.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn4si5007609ejc.571.2021.03.25.13.07.06; Thu, 25 Mar 2021 13:07:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=HPYH0hSt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=cisco.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230160AbhCYUEB (ORCPT + 99 others); Thu, 25 Mar 2021 16:04:01 -0400 Received: from rcdn-iport-1.cisco.com ([173.37.86.72]:53252 "EHLO rcdn-iport-1.cisco.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230189AbhCYUEB (ORCPT ); Thu, 25 Mar 2021 16:04:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=3186; q=dns/txt; s=iport; t=1616702641; x=1617912241; h=date:from:to:cc:subject:message-id:references: mime-version:content-transfer-encoding:in-reply-to; bh=BEUcHvcrI68gqzYOcJB+2Eo5dzEnIS+cOJz0im7Ye0s=; b=HPYH0hStD+pKhJUXvBq9Tvc02BLEU0vsh0Z17//mmav75tLANhaSIQm5 Mx7w2yGtymDjZ2LVu56BLKRjqJmARBxT9z5G1+CSKZIzxzzkOYf9nLk6b u3l/BANx5DxiI3/I9qywbkYKaL5uoIF0xEpcfBS4/MBmzBke9YQzqeuSa o=; X-IronPort-AV: E=Sophos;i="5.81,278,1610409600"; d="scan'208";a="867855113" Received: from alln-core-4.cisco.com ([173.36.13.137]) by rcdn-iport-1.cisco.com with ESMTP/TLS/DHE-RSA-SEED-SHA; 25 Mar 2021 20:04:00 +0000 Received: from zorba ([10.24.0.17]) by alln-core-4.cisco.com (8.15.2/8.15.2) with ESMTPS id 12PK3w7e004051 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 25 Mar 2021 20:03:59 GMT Date: Thu, 25 Mar 2021 13:03:57 -0700 From: Daniel Walker To: Christophe Leroy Cc: Will Deacon , Rob Herring , Daniel Gimpelevich , Andrew Morton , x86@kernel.org, linux-mips@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, xe-linux-external@cisco.com, Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , Ruslan Ruslichenko , Ruslan Bilovol , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 4/7] CMDLINE: powerpc: convert to generic builtin command line Message-ID: <20210325200357.GN109100@zorba> References: <20210309000247.2989531-5-danielwa@cisco.com> <20210309214051.GS109100@zorba> <9c5b8e33-026e-c9d6-c267-a5dd4a2b999c@csgroup.eu> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <9c5b8e33-026e-c9d6-c267-a5dd4a2b999c@csgroup.eu> X-Auto-Response-Suppress: DR, OOF, AutoReply X-Outbound-SMTP-Client: 10.24.0.17, [10.24.0.17] X-Outbound-Node: alln-core-4.cisco.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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@cisco.com > > > > Signed-off-by: Ruslan Ruslichenko > > > > Signed-off-by: Ruslan Bilovol > > > > Signed-off-by: Daniel Walker > > > > --- > > > > 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