]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
RealView: Allow PHYS_OFFSET at 0x70000000
authorCatalin Marinas <catalin.marinas@arm.com>
Mon, 1 Dec 2008 14:54:55 +0000 (14:54 +0000)
committerCatalin Marinas <catalin.marinas@arm.com>
Mon, 1 Dec 2008 14:54:55 +0000 (14:54 +0000)
RealView boards like PB11MPCore have 512MB of RAM available contiguously
at 0x70000000. Half of the memory is mirrored at 0x00000000 for
backwards compatibility. This patch adds the
CONFIG_REALVIEW_HIGH_PHYS_OFFSET option option to change the physical
base address so that the full amount of RAM is available to Linux. Note
that the EB board has 256MB of RAM also mirrored at 0x70000000, the only
board without this feature being PB1176.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm/mach-realview/Kconfig
arch/arm/mach-realview/Makefile.boot
arch/arm/mach-realview/include/mach/memory.h
arch/arm/mach-realview/realview_eb.c
arch/arm/mach-realview/realview_pb1176.c
arch/arm/mach-realview/realview_pb11mp.c

index 5ccde7cf39e868ce129c4f4fc204903d1f72f6d8..6695fb33afbf6a4058f4e0985a69a11e4685b07e 100644 (file)
@@ -37,4 +37,15 @@ config MACH_REALVIEW_PB1176
        help
          Include support for the ARM(R) RealView ARM1176 Platform Baseboard.
 
+config REALVIEW_HIGH_PHYS_OFFSET
+       bool "High physical base address for the RealView platform"
+       depends on !MACH_REALVIEW_PB1176
+       default y
+       help
+         RealView boards other than PB1176 have the RAM available at
+         0x70000000, 256MB of which being mirrored at 0x00000000. If
+         the board supports 512MB of RAM, this option allows the
+         memory to be accessed contiguously at the high physical
+         offset.
+
 endmenu
index c7e75acfe6c9b1911a5825c2b3136ad9b719d445..d97e003d3df4c2237be7e2b02a706d4819655b27 100644 (file)
@@ -1,4 +1,9 @@
+ifeq ($(CONFIG_REALVIEW_HIGH_PHYS_OFFSET),y)
+   zreladdr-y  := 0x70008000
+params_phys-y  := 0x70000100
+initrd_phys-y  := 0x70800000
+else
    zreladdr-y  := 0x00008000
 params_phys-y  := 0x00000100
 initrd_phys-y  := 0x00800000
-
+endif
index 0e673483a141d8087ca73cb12e10337de280e996..759ed10d74fe80422eb338c7ae3779cf5bd34567 100644 (file)
 /*
  * Physical DRAM offset.
  */
+#ifdef CONFIG_REALVIEW_HIGH_PHYS_OFFSET
+#define PHYS_OFFSET            UL(0x70000000)
+#else
 #define PHYS_OFFSET            UL(0x00000000)
+#endif
 
 /*
  * Virtual view <-> DMA view memory address translations
index eb829eb1ebe29dceb394952205fae68e52575c47..f6e04edf922df41d3f8d59cca92d72c7d96bcd2b 100644 (file)
@@ -392,7 +392,7 @@ MACHINE_START(REALVIEW_EB, "ARM-RealView EB")
        /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */
        .phys_io        = REALVIEW_EB_UART0_BASE,
        .io_pg_offst    = (IO_ADDRESS(REALVIEW_EB_UART0_BASE) >> 18) & 0xfffc,
-       .boot_params    = 0x00000100,
+       .boot_params    = PHYS_OFFSET + 0x00000100,
        .map_io         = realview_eb_map_io,
        .init_irq       = gic_init_irq,
        .timer          = &realview_eb_timer,
index cccdb3eb90fe94e0a41ffb6e30171759a6a3fe53..a9fac653b305a150072dee51f7791946802e4a3e 100644 (file)
@@ -284,7 +284,7 @@ MACHINE_START(REALVIEW_PB1176, "ARM-RealView PB1176")
        /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */
        .phys_io        = REALVIEW_PB1176_UART0_BASE,
        .io_pg_offst    = (IO_ADDRESS(REALVIEW_PB1176_UART0_BASE) >> 18) & 0xfffc,
-       .boot_params    = 0x00000100,
+       .boot_params    = PHYS_OFFSET + 0x00000100,
        .map_io         = realview_pb1176_map_io,
        .init_irq       = gic_init_irq,
        .timer          = &realview_pb1176_timer,
index 8b863148ec18b2b55f3571aa713d3bb787630ed5..8a27cd0a4741576a034fd5fb6127b6dbc2daf5f4 100644 (file)
@@ -334,7 +334,7 @@ MACHINE_START(REALVIEW_PB11MP, "ARM-RealView PB11MPCore")
        /* Maintainer: ARM Ltd/Deep Blue Solutions Ltd */
        .phys_io        = REALVIEW_PB11MP_UART0_BASE,
        .io_pg_offst    = (IO_ADDRESS(REALVIEW_PB11MP_UART0_BASE) >> 18) & 0xfffc,
-       .boot_params    = 0x00000100,
+       .boot_params    = PHYS_OFFSET + 0x00000100,
        .map_io         = realview_pb11mp_map_io,
        .init_irq       = gic_init_irq,
        .timer          = &realview_pb11mp_timer,