diff options
author | Jonas Gorski <jogo@openwrt.org> | 2015-10-12 07:13:03 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2015-11-11 02:38:37 -0500 |
commit | 2bcef9b457bbe159a5e3843e2578d8195e0b1c56 (patch) | |
tree | 6929a61bd517d5635812210fa2142be3314d0622 | |
parent | 2024972ef5330dcae47f400c586764d8f4cb0b04 (diff) |
MIPS: Make MIPS_CMDLINE_DTB default
Seval of-enabled machines (bmips, lantiq, xlp, pistachio, ralink) copied
the arguments from dtb to arcs_command_line to prevent the kernel from
overwriting them.
Since there is now an option to keep the dtb arguments, default to the
new option remove the "backup" to arcs_command_line in case of USE_OF is
enabled, except for those platforms that still take the bootloader
arguments or do not use any at all.
Signed-off-by: Jonas Gorski <jogo@openwrt.org>
Cc: linux-mips@linux-mips.org
Cc: Kevin Cernekee <cernekee@gmail.com>
Cc: Florian Fainelli <f.fainelli@gmail.com>
Cc: Zubair Lutfullah Kakakhel <Zubair.Kakakhel@imgtec.com>
Cc: James Hogan <james.hogan@imgtec.com>
Cc: John Crispin <blogic@openwrt.org>
Cc: Ganesan Ramalingam <ganesanr@broadcom.com>
Cc: Jayachandran C <jchandra@broadcom.com>
Cc: Andrew Bresticker <abrestic@chromium.org>
Cc: James Hartley <james.hartley@imgtec.com>
Patchwork: https://patchwork.linux-mips.org/patch/11285/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
-rw-r--r-- | arch/mips/Kconfig | 3 | ||||
-rw-r--r-- | arch/mips/bmips/setup.c | 1 | ||||
-rw-r--r-- | arch/mips/lantiq/prom.c | 2 | ||||
-rw-r--r-- | arch/mips/netlogic/xlp/dt.c | 1 | ||||
-rw-r--r-- | arch/mips/pistachio/init.c | 1 | ||||
-rw-r--r-- | arch/mips/ralink/of.c | 2 |
6 files changed, 3 insertions, 7 deletions
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index e3e65ae681c8..a65341a03712 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig | |||
@@ -2751,6 +2751,9 @@ endchoice | |||
2751 | 2751 | ||
2752 | choice | 2752 | choice |
2753 | prompt "Kernel command line type" if !CMDLINE_OVERRIDE | 2753 | prompt "Kernel command line type" if !CMDLINE_OVERRIDE |
2754 | default MIPS_CMDLINE_FROM_DTB if USE_OF && !ATH79 && !MACH_INGENIC && \ | ||
2755 | !MIPS_MALTA && !MIPS_SEAD3 && \ | ||
2756 | !CAVIUM_OCTEON_SOC | ||
2754 | default MIPS_CMDLINE_FROM_BOOTLOADER | 2757 | default MIPS_CMDLINE_FROM_BOOTLOADER |
2755 | 2758 | ||
2756 | config MIPS_CMDLINE_FROM_DTB | 2759 | config MIPS_CMDLINE_FROM_DTB |
diff --git a/arch/mips/bmips/setup.c b/arch/mips/bmips/setup.c index 526ec2789bb9..5b16d2955fbb 100644 --- a/arch/mips/bmips/setup.c +++ b/arch/mips/bmips/setup.c | |||
@@ -157,7 +157,6 @@ void __init plat_mem_setup(void) | |||
157 | panic("no dtb found"); | 157 | panic("no dtb found"); |
158 | 158 | ||
159 | __dt_setup_arch(dtb); | 159 | __dt_setup_arch(dtb); |
160 | strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE); | ||
161 | 160 | ||
162 | for (q = bmips_quirk_list; q->quirk_fn; q++) { | 161 | for (q = bmips_quirk_list; q->quirk_fn; q++) { |
163 | if (of_flat_dt_is_compatible(of_get_flat_dt_root(), | 162 | if (of_flat_dt_is_compatible(of_get_flat_dt_root(), |
diff --git a/arch/mips/lantiq/prom.c b/arch/mips/lantiq/prom.c index 0db099ecc016..297bcaa6b5d3 100644 --- a/arch/mips/lantiq/prom.c +++ b/arch/mips/lantiq/prom.c | |||
@@ -77,8 +77,6 @@ void __init plat_mem_setup(void) | |||
77 | * parsed resulting in our memory appearing | 77 | * parsed resulting in our memory appearing |
78 | */ | 78 | */ |
79 | __dt_setup_arch(__dtb_start); | 79 | __dt_setup_arch(__dtb_start); |
80 | |||
81 | strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE); | ||
82 | } | 80 | } |
83 | 81 | ||
84 | void __init device_tree_init(void) | 82 | void __init device_tree_init(void) |
diff --git a/arch/mips/netlogic/xlp/dt.c b/arch/mips/netlogic/xlp/dt.c index a625bdb6d6aa..856a6e6d296e 100644 --- a/arch/mips/netlogic/xlp/dt.c +++ b/arch/mips/netlogic/xlp/dt.c | |||
@@ -87,7 +87,6 @@ void __init *xlp_dt_init(void *fdtp) | |||
87 | void __init xlp_early_init_devtree(void) | 87 | void __init xlp_early_init_devtree(void) |
88 | { | 88 | { |
89 | __dt_setup_arch(xlp_fdt_blob); | 89 | __dt_setup_arch(xlp_fdt_blob); |
90 | strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE); | ||
91 | } | 90 | } |
92 | 91 | ||
93 | void __init device_tree_init(void) | 92 | void __init device_tree_init(void) |
diff --git a/arch/mips/pistachio/init.c b/arch/mips/pistachio/init.c index 8bd8ebb20a72..96ba2cc9ad3e 100644 --- a/arch/mips/pistachio/init.c +++ b/arch/mips/pistachio/init.c | |||
@@ -58,7 +58,6 @@ void __init plat_mem_setup(void) | |||
58 | panic("Device-tree not present"); | 58 | panic("Device-tree not present"); |
59 | 59 | ||
60 | __dt_setup_arch((void *)fw_arg1); | 60 | __dt_setup_arch((void *)fw_arg1); |
61 | strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE); | ||
62 | 61 | ||
63 | plat_setup_iocoherency(); | 62 | plat_setup_iocoherency(); |
64 | } | 63 | } |
diff --git a/arch/mips/ralink/of.c b/arch/mips/ralink/of.c index 0d30dcd63246..f9eda5d8f82c 100644 --- a/arch/mips/ralink/of.c +++ b/arch/mips/ralink/of.c | |||
@@ -74,8 +74,6 @@ void __init plat_mem_setup(void) | |||
74 | */ | 74 | */ |
75 | __dt_setup_arch(__dtb_start); | 75 | __dt_setup_arch(__dtb_start); |
76 | 76 | ||
77 | strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE); | ||
78 | |||
79 | of_scan_flat_dt(early_init_dt_find_memory, NULL); | 77 | of_scan_flat_dt(early_init_dt_find_memory, NULL); |
80 | if (memory_dtb) | 78 | if (memory_dtb) |
81 | of_scan_flat_dt(early_init_dt_scan_memory, NULL); | 79 | of_scan_flat_dt(early_init_dt_scan_memory, NULL); |