summaryrefslogtreecommitdiffstats
path: root/arch/arm/boards/nhk8815
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2011-07-29 11:43:48 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2011-08-01 16:32:00 +0200
commitf9f35ee93821048bbace895c5c688bafbda2c3f3 (patch)
treeadab257c88226972d58ae3e47aeea7f7a3ae36b5 /arch/arm/boards/nhk8815
parent2222dbc28668e478ec27cff13f8d4c9498d8519a (diff)
downloadbarebox-f9f35ee93821048bbace895c5c688bafbda2c3f3.tar.gz
barebox-f9f35ee93821048bbace895c5c688bafbda2c3f3.tar.xz
ARM boards: move sdram setup before mmu setup
The new MMU setup will need SDRAM base addresses and sizes. For this reason convert the MMU enabled ARM boards: - move mem setup to mem_initcall. This is early but still makes sure that we already have the console available - move MMU setup in this initcall temporary as after the mmu_init will generic Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Diffstat (limited to 'arch/arm/boards/nhk8815')
-rw-r--r--arch/arm/boards/nhk8815/setup.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/arm/boards/nhk8815/setup.c b/arch/arm/boards/nhk8815/setup.c
index da6be93406..dcf716620d 100644
--- a/arch/arm/boards/nhk8815/setup.c
+++ b/arch/arm/boards/nhk8815/setup.c
@@ -76,10 +76,16 @@ static struct device_d nhk8815_nand_device = {
.platform_data = &nhk8815_nand_data,
};
-static int nhk8815_devices_init(void)
+static int nhk8815_mem_init(void)
{
st8815_add_device_sdram(64 * 1024 *1024);
+ return 0;
+}
+mem_initcall(nhk8815_mem_init);
+
+static int nhk8815_devices_init(void)
+{
writel(0xC37800F0, NOMADIK_GPIO1_BASE + 0x20);
writel(0x00000000, NOMADIK_GPIO1_BASE + 0x24);
writel(0x00000000, NOMADIK_GPIO1_BASE + 0x28);