On Tue, Oct 31, 2006 at 01:40:07PM +0900, Yoichi Yuasa wrote: > This patch has fixed wrong prom_getcmdline() definition. Fortunately an __init declaration of a function leaves the compiler entirely unimpressed. Your patch only scratched the surface of the problem; so I went for below patch. Further cleanup should be done but that would be unsuitable for 2.6.19 now that -rc4 is out. Ralf diff --git a/arch/mips/au1000/common/prom.c b/arch/mips/au1000/common/prom.c index b4b010a..6fce60a 100644 --- a/arch/mips/au1000/common/prom.c +++ b/arch/mips/au1000/common/prom.c @@ -47,7 +47,7 @@ extern int prom_argc; extern char **prom_argv, **prom_envp; -char * prom_getcmdline(void) +char * __init_or_module prom_getcmdline(void) { return &(arcs_cmdline[0]); } diff --git a/arch/mips/au1000/common/setup.c b/arch/mips/au1000/common/setup.c index 377ae0d..919172d 100644 --- a/arch/mips/au1000/common/setup.c +++ b/arch/mips/au1000/common/setup.c @@ -43,7 +43,7 @@ #include <asm/pgtable.h> #include <asm/mach-au1x00/au1000.h> #include <asm/time.h> -extern char * __init prom_getcmdline(void); +extern char * prom_getcmdline(void); extern void __init board_setup(void); extern void au1000_restart(char *); extern void au1000_halt(void); diff --git a/drivers/net/au1000_eth.c b/drivers/net/au1000_eth.c index 4873dc6..7db3c8a 100644 --- a/drivers/net/au1000_eth.c +++ b/drivers/net/au1000_eth.c @@ -102,7 +102,7 @@ static void enable_mac(struct net_device // externs extern int get_ethernet_addr(char *ethernet_addr); extern void str2eaddr(unsigned char *ea, unsigned char *str); -extern char * __init prom_getcmdline(void); +extern char * prom_getcmdline(void); /* * Theory of operation diff --git a/drivers/net/gt64240eth.c b/drivers/net/gt64240eth.c index f543930..7859202 100644 --- a/drivers/net/gt64240eth.c +++ b/drivers/net/gt64240eth.c @@ -127,7 +127,7 @@ static void gt64240_tx_timeout(struct ne static void gt64240_set_rx_mode(struct net_device *dev); static struct net_device_stats *gt64240_get_stats(struct net_device *dev); -extern char *__init prom_getcmdline(void); +extern char * prom_getcmdline(void); extern int prom_get_mac_addrs(unsigned char station_addr[NUM_INTERFACES][6]);