Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1240764

Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section

From Rob Herring <robh@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section
Date 2015-10-06 19:20 +0200
Message-ID <qgE4a-49R-25@gated-at.bofh.it> (permalink)
References <qgCOL-2bP-33@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Oct 6, 2015 at 10:47 AM, Daniel Walker <danielwa@cisco.com> wrote:
> It looks like there's some seepage of cmdline stuff into
> the generic device tree code. This conflicts with the
> generic cmdline implementation so I remove it in the case
> when that's enabled.

Nice series in general. I've had passing desire to do this every time
I run into the command line code.

The DT handling of the command line is generic across architectures.
The current design is working around that the kernel command line code
is not that way. I think we can take this a bit further by making the
generic DT code add the command line string directly rather than
relying on the arch to do that. Then we can remove all command line
handling from the arch code. I would also look at whether we can make
boot_command_line static rather than directly accessed. We might have
to leave it public for now, but could treat it as static for generic
cmdline case.

Rob

> Cc: xe-kernel@external.cisco.com
> Cc: Daniel Walker <dwalker@fifo99.com>
> Signed-off-by: Daniel Walker <danielwa@cisco.com>
> ---
>  drivers/of/fdt.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
> index 6e82bc42..80f1e48 100644
> --- a/drivers/of/fdt.c
> +++ b/drivers/of/fdt.c
> @@ -953,7 +953,7 @@ int __init early_init_dt_scan_chosen(unsigned long node, const char *uname,
>          * managed to set the command line, unless CONFIG_CMDLINE_FORCE
>          * is set in which case we override whatever was found earlier.
>          */
> -#ifdef CONFIG_CMDLINE
> +#if defined(CONFIG_CMDLINE) && !defined(CONFIG_GENERIC_CMDLINE)
>  #ifndef CONFIG_CMDLINE_FORCE
>         if (!((char *)data)[0])
>  #endif
> --
> 2.1.4
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Daniel Walker <danielwa@cisco.com> - 2015-10-06 18:00 +0200
  Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Rob Herring <robh@kernel.org> - 2015-10-06 19:20 +0200
    Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section dwalker@fifo99.com - 2015-10-07 18:50 +0200
      Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Rob Herring <robh@kernel.org> - 2015-10-07 23:50 +0200
        Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Daniel Walker <danielwa@cisco.com> - 2015-10-13 22:30 +0200
          Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Rob Herring <robh@kernel.org> - 2015-10-13 23:20 +0200
            Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Daniel Walker <danielwa@cisco.com> - 2015-10-14 16:50 +0200
              Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Rob Herring <robh@kernel.org> - 2015-10-14 20:00 +0200
                Re: [PATCH-RFC 6/7] drivers: of: ifdef out cmdline section Daniel Walker <danielwa@cisco.com> - 2015-10-14 21:20 +0200

csiph-web