Fix board_type allocation (again)
[openwrt.git] / target / linux / rb532 / files / arch / mips / rb500 / prom.c
index e6ac243..2a33c0a 100644 (file)
@@ -103,9 +103,9 @@ void __init prom_init(void)
        add_memory_region(ddr->ddrbase + 0x400, memsize - 0x600, BOOT_MEM_RAM);
 }
 
-void prom_free_prom_memory(void)
+void __init prom_free_prom_memory(void)
 {
-       /* FIXME: STUB */
+       /* No prom memory to free */
 }
 
 extern char _image_cmdline;
@@ -136,6 +136,7 @@ void __init prom_setup_cmdline(void){
 #endif
                if (i>0) *(cp++) = ' ';
                if (strncmp(prom_argv[i], BOARD_TAG, sizeof(BOARD_TAG) - 1) == 0) {
+                       board_type = (char *)kzalloc((sizeof(prom_argv[i]) + sizeof(BOARD_TAG) -1), GFP_KERNEL);
                        strcpy(board_type, prom_argv[i] + sizeof(BOARD_TAG) -1);
                }
                if (strncmp(prom_argv[i], GPIO_TAG, sizeof(GPIO_TAG) - 1) == 0) {
This page took 0.021923 seconds and 4 git commands to generate.