diff options
author | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-09-10 18:30:06 +0000 |
---|---|---|
committer | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-09-10 18:30:06 +0000 |
commit | f23543c3609cd91efafedc86f8557f4939c4d201 (patch) | |
tree | 7bf8ccbc10266a15394f36a31d6d5b797225a587 /target/linux/adm5120/files/arch/mips | |
parent | 31cee17e3864f7a4f4c2e3ab662c78425210b39d (diff) |
adm5120: use the generic image_cmdline hack
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@17564 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/adm5120/files/arch/mips')
-rw-r--r-- | target/linux/adm5120/files/arch/mips/adm5120/common/prom.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c b/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c index 85b61ab8a4..5b2e45defe 100644 --- a/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c +++ b/target/linux/adm5120/files/arch/mips/adm5120/common/prom.c @@ -237,18 +237,22 @@ static void __init prom_detect_machtype(void) adm5120_mach_type = MACH_ADM5120_GENERIC; } -/* TODO: this is an ugly hack for RouterBOARDS */ -extern char _image_cmdline; +#ifdef CONFIG_IMAGE_CMDLINE_HACK +extern char __image_cmdline[]; + static void __init prom_init_cmdline(void) { char *cmd; /* init command line, register a default kernel command line */ - cmd = &_image_cmdline + 8; + cmd = __image_cmdline; if (strlen(cmd) > 0) strlcpy(arcs_cmdline, cmd, sizeof(arcs_cmdline)); } +#else +static void inline prom_init_cmdline(void) {} +#endif /* CONFIG_IMAGE_CMDLINE_HACK */ #define UART_READ(r) \ __raw_readl((void __iomem *)(KSEG1ADDR(ADM5120_UART0_BASE)+(r))) |