[patch 10/26] Dynamic kernel command-line - ia64

Bernhard Walle
2007-01-18T13:06:16Z

[-- Attachment #1: dynamic-kernel-command-line-ia64.diff --]
[-- Type: text/plain, Size: 2173 bytes --]

1. Rename saved_command_line into boot_command_line.
2. Set command_line as __initdata.

Signed-off-by: Alon Bar-Lev <alon.barlev@gmail.com>

---
arch/ia64/kernel/efi.c | 4 ++--
arch/ia64/kernel/sal.c | 4 ++--
arch/ia64/kernel/setup.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)

Index: linux-2.6.20-rc4-mm1/arch/ia64/kernel/efi.c
===================================================================
--- linux-2.6.20-rc4-mm1.orig/arch/ia64/kernel/efi.c
+++ linux-2.6.20-rc4-mm1/arch/ia64/kernel/efi.c
@@ -413,11 +413,11 @@ efi_init (void)
efi_char16_t *c16;
u64 efi_desc_size;
char *cp, vendor[100] = "unknown";
- extern char saved_command_line[];
+ extern char __initdata boot_command_line[];
int i;

/* it's too early to be able to use the standard kernel command line support... */
- for (cp = saved_command_line; *cp; ) {
+ for (cp = boot_command_line; *cp; ) {
if (memcmp(cp, "mem=", 4) == 0) {
mem_limit = memparse(cp + 4, &cp);
} else if (memcmp(cp, "max_addr=", 9) == 0) {
Index: linux-2.6.20-rc4-mm1/arch/ia64/kernel/sal.c
===================================================================
--- linux-2.6.20-rc4-mm1.orig/arch/ia64/kernel/sal.c
+++ linux-2.6.20-rc4-mm1/arch/ia64/kernel/sal.c
@@ -194,9 +194,9 @@ static void __init
chk_nointroute_opt(void)
{
char *cp;
- extern char saved_command_line[];
+ extern char __initdata boot_command_line[];

- for (cp = saved_command_line; *cp; ) {
+ for (cp = boot_command_line; *cp; ) {
if (memcmp(cp, "nointroute", 10) == 0) {
no_int_routing = 1;
printk ("no_int_routing on\n");
Index: linux-2.6.20-rc4-mm1/arch/ia64/kernel/setup.c
===================================================================
--- linux-2.6.20-rc4-mm1.orig/arch/ia64/kernel/setup.c
+++ linux-2.6.20-rc4-mm1/arch/ia64/kernel/setup.c
@@ -463,7 +463,7 @@ setup_arch (char **cmdline_p)
ia64_patch_vtop((u64) __start___vtop_patchlist, (u64) __end___vtop_patchlist);

*cmdline_p = __va(ia64_boot_param->command_line);
- strlcpy(saved_command_line, *cmdline_p, COMMAND_LINE_SIZE);
+ strlcpy(boot_command_line, *cmdline_p, COMMAND_LINE_SIZE);

efi_init();
io_port_init();

--