]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[ARM] Kirkwood: allow configuring mbus window for on-chip sram
authorLennert Buytenhek <buytenh@wantstofly.org>
Sun, 31 Aug 2008 05:39:19 +0000 (07:39 +0200)
committerNicolas Pitre <nico@cam.org>
Thu, 25 Sep 2008 20:27:22 +0000 (16:27 -0400)
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
arch/arm/mach-kirkwood/addr-map.c
arch/arm/mach-kirkwood/common.h

index c79f492072f995d47818c4e1df21f5a0f9e6c456..5db4f0bbe5ee2c020320b4ef4bf09826e2d1521e 100644 (file)
@@ -48,6 +48,7 @@
 
 
 struct mbus_dram_target_info kirkwood_mbus_dram_info;
+static int __initdata win_alloc_count;
 
 static int __init cpu_win_can_remap(int win)
 {
@@ -111,6 +112,8 @@ void __init kirkwood_setup_cpu_mbus(void)
        setup_cpu_win(2, KIRKWOOD_NAND_MEM_PHYS_BASE, KIRKWOOD_NAND_MEM_SIZE,
                      TARGET_DEV_BUS, ATTR_DEV_NAND, -1);
 
+       win_alloc_count = 3;
+
        /*
         * Setup MBUS dram target info.
         */
@@ -137,3 +140,8 @@ void __init kirkwood_setup_cpu_mbus(void)
        }
        kirkwood_mbus_dram_info.num_cs = cs;
 }
+
+void __init kirkwood_setup_sram_win(u32 base, u32 size)
+{
+       setup_cpu_win(win_alloc_count++, base, size, 0x03, 0x00, -1);
+}
index 02abef1b32191413a9c28bd1fe234a55bc40eae0..8fa0f6a2763526bf613033eb08a5dfeb6e0b33e1 100644 (file)
@@ -23,10 +23,7 @@ void kirkwood_init_irq(void);
 
 extern struct mbus_dram_target_info kirkwood_mbus_dram_info;
 void kirkwood_setup_cpu_mbus(void);
-void kirkwood_setup_pcie_io_win(int window, u32 base, u32 size,
-                               int maj, int min);
-void kirkwood_setup_pcie_mem_win(int window, u32 base, u32 size,
-                                int maj, int min);
+void kirkwood_setup_sram_win(u32 base, u32 size);
 
 void kirkwood_pcie_id(u32 *dev, u32 *rev);