[PATCHv2 3/6] ARM OMAP: Apply RAM device register functions to boards
Teresa Gámez
t.gamez at phytec.de
Thu Dec 20 09:22:31 EST 2012
Apply RAM and SRAM register functions to all OMAP boards.
Signed-off-by: Teresa Gámez <t.gamez at phytec.de>
---
arch/arm/boards/archosg9/board.c | 2 +-
arch/arm/boards/beagle/board.c | 2 +-
arch/arm/boards/beaglebone/board.c | 2 +-
arch/arm/boards/omap343xdsp/board.c | 2 +-
arch/arm/boards/omap3evm/board.c | 2 +-
arch/arm/boards/panda/board.c | 2 +-
arch/arm/boards/pcm049/board.c | 5 ++---
arch/arm/boards/phycard-a-l1/pca-a-l1.c | 5 ++---
arch/arm/boards/phycard-a-xl2/pca-a-xl2.c | 6 +++---
9 files changed, 13 insertions(+), 15 deletions(-)
diff --git a/arch/arm/boards/archosg9/board.c b/arch/arm/boards/archosg9/board.c
index 5f62748..1911c62 100644
--- a/arch/arm/boards/archosg9/board.c
+++ b/arch/arm/boards/archosg9/board.c
@@ -35,7 +35,7 @@ static int archosg9_console_init(void){
console_initcall(archosg9_console_init);
static int archosg9_mem_init(void){
- arm_add_mem_device("ram0", 0x80000000, SZ_1G);
+ omap_add_ram0(SZ_1G);
return 0;
}
mem_initcall(archosg9_mem_init);
diff --git a/arch/arm/boards/beagle/board.c b/arch/arm/boards/beagle/board.c
index 04c4d32..e0e1da6 100644
--- a/arch/arm/boards/beagle/board.c
+++ b/arch/arm/boards/beagle/board.c
@@ -280,7 +280,7 @@ static struct gpmc_nand_platform_data nand_plat = {
static int beagle_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, 128 * 1024 * 1024);
+ omap_add_ram0(SZ_128M);
return 0;
}
diff --git a/arch/arm/boards/beaglebone/board.c b/arch/arm/boards/beaglebone/board.c
index a7e3e74..f9ac7a4 100644
--- a/arch/arm/boards/beaglebone/board.c
+++ b/arch/arm/boards/beaglebone/board.c
@@ -307,7 +307,7 @@ console_initcall(beaglebone_console_init);
static int beaglebone_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, 256 * 1024 * 1024);
+ omap_add_ram0(256 * 1024 * 1024);
return 0;
}
diff --git a/arch/arm/boards/omap343xdsp/board.c b/arch/arm/boards/omap343xdsp/board.c
index eb752ff..6dbbc4c 100644
--- a/arch/arm/boards/omap343xdsp/board.c
+++ b/arch/arm/boards/omap343xdsp/board.c
@@ -620,7 +620,7 @@ console_initcall(sdp3430_console_init);
static int sdp3430_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, 128 * 1024 * 1024);
+ omap_add_ram0(128 * 1024 * 1024);
return 0;
}
diff --git a/arch/arm/boards/omap3evm/board.c b/arch/arm/boards/omap3evm/board.c
index 03d3ab8..f636fe3 100644
--- a/arch/arm/boards/omap3evm/board.c
+++ b/arch/arm/boards/omap3evm/board.c
@@ -232,7 +232,7 @@ console_initcall(omap3evm_init_console);
static int omap3evm_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, 128 * 1024 * 1024);
+ omap_add_ram0(SZ_128M);
return 0;
}
diff --git a/arch/arm/boards/panda/board.c b/arch/arm/boards/panda/board.c
index 5b27f46..8054a6a 100644
--- a/arch/arm/boards/panda/board.c
+++ b/arch/arm/boards/panda/board.c
@@ -44,7 +44,7 @@ console_initcall(panda_console_init);
static int panda_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, SZ_1G);
+ omap_add_ram0(SZ_1G);
return 0;
}
diff --git a/arch/arm/boards/pcm049/board.c b/arch/arm/boards/pcm049/board.c
index ca3f906..680539a 100644
--- a/arch/arm/boards/pcm049/board.c
+++ b/arch/arm/boards/pcm049/board.c
@@ -49,10 +49,9 @@ console_initcall(pcm049_console_init);
static int pcm049_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, SZ_512M);
+ omap_add_ram0(SZ_512M);
- add_mem_device("sram0", 0x40300000, 48 * 1024,
- IORESOURCE_MEM_WRITEABLE);
+ omap44xx_add_sram0();
return 0;
}
mem_initcall(pcm049_mem_init);
diff --git a/arch/arm/boards/phycard-a-l1/pca-a-l1.c b/arch/arm/boards/phycard-a-l1/pca-a-l1.c
index b582d71..4b307a6 100644
--- a/arch/arm/boards/phycard-a-l1/pca-a-l1.c
+++ b/arch/arm/boards/phycard-a-l1/pca-a-l1.c
@@ -358,10 +358,9 @@ static int pcaal1_mem_init(void)
*/
gpmc_generic_init(0x10);
#endif
- add_mem_device("sram0", OMAP_SRAM_BASE, 60 * SZ_1K,
- IORESOURCE_MEM_WRITEABLE);
+ omap3_add_sram0();
- arm_add_mem_device("ram0", OMAP_SDRC_CS0, get_sdr_cs_size(SDRC_CS0_OSET));
+ omap_add_ram0(get_sdr_cs_size(SDRC_CS0_OSET));
printf("found %s at SDCS0\n", size_human_readable(get_sdr_cs_size(SDRC_CS0_OSET)));
if ((get_sdr_cs_size(SDRC_CS1_OSET) != 0) && (get_sdr_cs1_base() != OMAP_SDRC_CS0)) {
diff --git a/arch/arm/boards/phycard-a-xl2/pca-a-xl2.c b/arch/arm/boards/phycard-a-xl2/pca-a-xl2.c
index 3931f57..be7060f 100644
--- a/arch/arm/boards/phycard-a-xl2/pca-a-xl2.c
+++ b/arch/arm/boards/phycard-a-xl2/pca-a-xl2.c
@@ -50,10 +50,10 @@ console_initcall(pcaaxl2_console_init);
static int pcaaxl2_mem_init(void)
{
- arm_add_mem_device("ram0", 0x80000000, SZ_512M);
+ omap_add_ram0(SZ_512M);
+
+ omap44xx_add_sram0();
- add_mem_device("sram0", 0x40300000, 48 * 1024,
- IORESOURCE_MEM_WRITEABLE);
return 0;
}
mem_initcall(pcaaxl2_mem_init);
--
1.7.0.4
More information about the barebox
mailing list