diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2009-03-26 23:10:11 +0000 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-03-26 23:10:11 +0000 |
commit | 542f869f1826f092606efd0c4c771f070d1314f5 (patch) | |
tree | 9c9d265ab0c87ea7862ccb70933f33d3d7011334 /arch/arm/mach-gemini/mm.c | |
parent | e8b374bb6c888a70530d800c9e2fcd153e2c325d (diff) | |
parent | 839e642f3dda44a35c6a91780bff41d84c288022 (diff) | |
download | linux-3.10-542f869f1826f092606efd0c4c771f070d1314f5.tar.gz linux-3.10-542f869f1826f092606efd0c4c771f070d1314f5.tar.bz2 linux-3.10-542f869f1826f092606efd0c4c771f070d1314f5.zip |
Merge branch 'for-rmk' of git://gitorious.org/linux-gemini/mainline into devel
Conflicts:
arch/arm/mm/Kconfig
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-gemini/mm.c')
-rw-r--r-- | arch/arm/mach-gemini/mm.c | 82 |
1 files changed, 82 insertions, 0 deletions
diff --git a/arch/arm/mach-gemini/mm.c b/arch/arm/mach-gemini/mm.c new file mode 100644 index 00000000000..51948242ec0 --- /dev/null +++ b/arch/arm/mach-gemini/mm.c @@ -0,0 +1,82 @@ +/* + * Static mappings for Gemini + * + * Copyright (C) 2001-2006 Storlink, Corp. + * Copyright (C) 2008-2009 Paulius Zaleckas <paulius.zaleckas@teltonika.lt> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + */ +#include <linux/mm.h> +#include <linux/init.h> + +#include <asm/mach/map.h> + +#include <mach/hardware.h> + +/* Page table mapping for I/O region */ +static struct map_desc gemini_io_desc[] __initdata = { + { + .virtual = IO_ADDRESS(GEMINI_GLOBAL_BASE), + .pfn =__phys_to_pfn(GEMINI_GLOBAL_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_UART_BASE), + .pfn = __phys_to_pfn(GEMINI_UART_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_TIMER_BASE), + .pfn = __phys_to_pfn(GEMINI_TIMER_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_INTERRUPT_BASE), + .pfn = __phys_to_pfn(GEMINI_INTERRUPT_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_POWER_CTRL_BASE), + .pfn = __phys_to_pfn(GEMINI_POWER_CTRL_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_GPIO_BASE(0)), + .pfn = __phys_to_pfn(GEMINI_GPIO_BASE(0)), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_GPIO_BASE(1)), + .pfn = __phys_to_pfn(GEMINI_GPIO_BASE(1)), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_GPIO_BASE(2)), + .pfn = __phys_to_pfn(GEMINI_GPIO_BASE(2)), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_FLASH_CTRL_BASE), + .pfn = __phys_to_pfn(GEMINI_FLASH_CTRL_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_DRAM_CTRL_BASE), + .pfn = __phys_to_pfn(GEMINI_DRAM_CTRL_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, { + .virtual = IO_ADDRESS(GEMINI_GENERAL_DMA_BASE), + .pfn = __phys_to_pfn(GEMINI_GENERAL_DMA_BASE), + .length = SZ_512K, + .type = MT_DEVICE, + }, +}; + +void __init gemini_map_io(void) +{ + iotable_init(gemini_io_desc, ARRAY_SIZE(gemini_io_desc)); +} |