[ARM] pxa/cm-x300: add .fixup method to enable second DRAM bank
authorMike Rapoport <mike@compulab.co.il>
Thu, 4 Jun 2009 07:44:54 +0000 (10:44 +0300)
committerEric Miao <eric.y.miao@gmail.com>
Fri, 5 Jun 2009 02:50:27 +0000 (10:50 +0800)
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
arch/arm/mach-pxa/cm-x300.c

index cd39fa22ba2dac34e649f8cde35c24a5fe64c810..465da26591bd3e863bbce2a2bd8f8f47e1c321f7 100644 (file)
@@ -28,6 +28,7 @@
 
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
+#include <asm/setup.h>
 
 #include <mach/pxa300.h>
 #include <mach/pxafb.h>
@@ -494,6 +495,18 @@ static void __init cm_x300_init(void)
        cm_x300_init_rtc();
 }
 
+static void __init cm_x300_fixup(struct machine_desc *mdesc, struct tag *tags,
+                                char **cmdline, struct meminfo *mi)
+{
+       mi->nr_banks = 2;
+       mi->bank[0].start = 0xa0000000;
+       mi->bank[0].node = 0;
+       mi->bank[0].size = (64*1024*1024);
+       mi->bank[1].start = 0xc0000000;
+       mi->bank[1].node = 0;
+       mi->bank[1].size = (64*1024*1024);
+}
+
 MACHINE_START(CM_X300, "CM-X300 module")
        .phys_io        = 0x40000000,
        .boot_params    = 0xa0000100,
@@ -502,4 +515,5 @@ MACHINE_START(CM_X300, "CM-X300 module")
        .init_irq       = pxa3xx_init_irq,
        .timer          = &pxa_timer,
        .init_machine   = cm_x300_init,
+       .fixup          = cm_x300_fixup,
 MACHINE_END