Skip to content

Commit 13a0ea2

Browse files
pcercueitsbogend
authored andcommitted
MIPS: generic: Init command line with fw_init_cmdline()
The function bootcmdline_init() in arch/mips/kernel/setup.c will populate the boot_command_line string using the parameters hardcoded in the kernel, and those provided in the devicetree file. Then, it would append the content of the arcs_cmdline variable, which is filled by the board's plat_mem_setup() function. The plat_mem_setup() function for the generic MIPS board would just copy the current boot_command_line to arcs_cmdline, which is nonsense for two reasons: - the result will be appended to the boot_command_line anyway, so all it does is duplicate every single parameter on the command line; - the code did not perform at all what it's supposed to, which is to retrieve the parameters passed by the bootloader. Fix this by calling fw_init_cmdline() in plat_mem_setup(), which will properly initialize arcs_cmdline to the parameters passed by the bootloader. Signed-off-by: Paul Cercueil <paul@crapouillou.net> Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
1 parent 8405419 commit 13a0ea2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎arch/mips/generic/init.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ void __init plat_mem_setup(void)
106106
if (mach && mach->fixup_fdt)
107107
fdt = mach->fixup_fdt(fdt, mach_match_data);
108108

109-
strlcpy(arcs_cmdline, boot_command_line, COMMAND_LINE_SIZE);
109+
fw_init_cmdline();
110110
__dt_setup_arch((void *)fdt);
111111
}
112112

0 commit comments

Comments
 (0)