ARM: pxa: Introduce pxa{25x,27x,3xx}_map_io()
[linux-2.6-block.git] / arch / arm / mach-pxa / pxa27x.c
index d1fbf29d561c5cbe4b49e634ccb9953f6b1a4f27..71dbee42edf9e0673f7bf01d6211f3a99c778f51 100644 (file)
@@ -18,6 +18,7 @@
 #include <linux/platform_device.h>
 #include <linux/sysdev.h>
 
+#include <asm/mach/map.h>
 #include <mach/hardware.h>
 #include <asm/irq.h>
 #include <mach/irqs.h>
@@ -370,6 +371,27 @@ void __init pxa27x_init_irq(void)
        pxa_init_gpio(IRQ_GPIO_2_x, 2, 120, pxa27x_set_wake);
 }
 
+static struct map_desc pxa27x_io_desc[] __initdata = {
+       {       /* Mem Ctl */
+               .virtual        =  0xf6000000,
+               .pfn            = __phys_to_pfn(0x48000000),
+               .length         = 0x00200000,
+               .type           = MT_DEVICE
+       }, {    /* IMem ctl */
+               .virtual        =  0xfe000000,
+               .pfn            = __phys_to_pfn(0x58000000),
+               .length         = 0x00100000,
+               .type           = MT_DEVICE
+       },
+};
+
+void __init pxa27x_map_io(void)
+{
+       pxa_map_io();
+       iotable_init(ARRAY_AND_SIZE(pxa27x_io_desc));
+       pxa27x_get_clk_frequency_khz(1);
+}
+
 /*
  * device registration specific to PXA27x.
  */