]> rtime.felk.cvut.cz Git - mcf548x/linux.git/blobdiff - arch/m68k/coldfire/config.c
Current (FEC from 2.6.31 port, no CAN, no I2C, no PCI)
[mcf548x/linux.git] / arch / m68k / coldfire / config.c
index aac09391a04ca1bae09e4b2ca5be46bdde912c05..23be9d43586514d2778b682f023a8981235ca09c 100644 (file)
 #include <asm/bootinfo.h>
 #include <asm/machdep.h>
 #include <asm/coldfire.h>
-#include <asm/cache.h>
+#include <asm/mcfcache.h>
 #include <asm/cacheflush.h>
 #include <asm/io.h>
-#include <asm/mmu.h>
+#include <asm/mcfmmu.h>
 #include <asm/setup.h>
 #include <asm/irq.h>
 #include <asm/traps.h>
 
 #include <asm/mcfsim.h>
 
-#ifdef CONFIG_UBOOT
-
-#if defined(CONFIG_M5445X)
-#define UBOOT_EXTRA_CLOCKS
-#elif defined(CONFIG_M547X_8X)
-#define UBOOT_PCI
-#endif
-
-#endif
-
 #include <asm/bootinfo.h>
 
 #ifdef CONFIG_M5445X
@@ -56,7 +46,7 @@
 #endif
 
 #ifdef CONFIG_M547X_8X
-#include <asm/m5485gpt.h>
+#include <asm/m548xgpt.h>
 #endif
 
 extern int get_irq_list(struct seq_file *p, void *v);
@@ -67,6 +57,7 @@ extern unsigned long availmem;
 
 #if CONFIG_UBOOT
 extern char m68k_command_line[CL_SIZE];
+struct mem_info m68k_ramdisk;
 #endif
 
 static int irq_enable[NR_IRQS];
@@ -111,11 +102,22 @@ int __init uboot_commandline(char *bootargs)
        
        int len = 0, cmd_line_len;
        unsigned long cmd_line_stop, cmd_line_start;
+       unsigned long initrd_start, initrd_stop;
        u32 offset = PAGE_OFFSET_RAW - PHYS_OFFSET;
 
        //uboot_init_sp parameters - must add offset to them !!
        cmd_line_start = uboot_init_sp + 16 + offset;
-       cmd_line_start = uboot_init_sp + 20 + offset;
+       cmd_line_stop = uboot_init_sp + 20 + offset;
+
+       initrd_start = uboot_init_sp + 8 + offset;
+       
+       if ( *((unsigned long*)initrd_start) != 0)
+       {
+               initrd_stop = uboot_init_sp + 12 + offset;
+
+               m68k_ramdisk.addr = initrd_start;
+               m68k_ramdisk.size = *((unsigned long*)initrd_stop) - *((unsigned long*)initrd_start);
+       }
 
        /* copy command line */
        cmd_line_len = cmd_line_stop - cmd_line_start;