diff options
author | Tony Lindgren <tony@atomide.com> | 2011-10-04 16:52:57 -0400 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2011-10-19 19:34:10 -0400 |
commit | a66cb3454f220f49f900646ebdc76cb943319eb7 (patch) | |
tree | bc5f79989a037e3b3d0b067bc9cac9868291b490 /arch/arm/mach-omap2/io.c | |
parent | fee926bb0d399b1eaaf38f9f694bbf2747c4b8a2 (diff) |
ARM: OMAP: Map SRAM later on with ioremap_exec()
This allows us to remove omap hacks for map_io.
Acked-by: Nicolas Pitre <nicolas.pitre@linaro.org>
Reviewed-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Tested-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/io.c')
-rw-r--r-- | arch/arm/mach-omap2/io.c | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c index e8123d010307..b42bbb8f252d 100644 --- a/arch/arm/mach-omap2/io.c +++ b/arch/arm/mach-omap2/io.c | |||
@@ -35,8 +35,8 @@ | |||
35 | #include "clock2xxx.h" | 35 | #include "clock2xxx.h" |
36 | #include "clock3xxx.h" | 36 | #include "clock3xxx.h" |
37 | #include "clock44xx.h" | 37 | #include "clock44xx.h" |
38 | #include "io.h" | ||
39 | 38 | ||
39 | #include <plat/common.h> | ||
40 | #include <plat/omap-pm.h> | 40 | #include <plat/omap-pm.h> |
41 | #include "voltage.h" | 41 | #include "voltage.h" |
42 | #include "powerdomain.h" | 42 | #include "powerdomain.h" |
@@ -240,22 +240,11 @@ static struct map_desc omap44xx_io_desc[] __initdata = { | |||
240 | }; | 240 | }; |
241 | #endif | 241 | #endif |
242 | 242 | ||
243 | static void __init _omap2_map_common_io(void) | ||
244 | { | ||
245 | /* Normally devicemaps_init() would flush caches and tlb after | ||
246 | * mdesc->map_io(), but we must also do it here because of the CPU | ||
247 | * revision check below. | ||
248 | */ | ||
249 | local_flush_tlb_all(); | ||
250 | flush_cache_all(); | ||
251 | } | ||
252 | |||
253 | #ifdef CONFIG_SOC_OMAP2420 | 243 | #ifdef CONFIG_SOC_OMAP2420 |
254 | void __init omap242x_map_common_io(void) | 244 | void __init omap242x_map_common_io(void) |
255 | { | 245 | { |
256 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 246 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
257 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); | 247 | iotable_init(omap242x_io_desc, ARRAY_SIZE(omap242x_io_desc)); |
258 | _omap2_map_common_io(); | ||
259 | } | 248 | } |
260 | #endif | 249 | #endif |
261 | 250 | ||
@@ -264,7 +253,6 @@ void __init omap243x_map_common_io(void) | |||
264 | { | 253 | { |
265 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); | 254 | iotable_init(omap24xx_io_desc, ARRAY_SIZE(omap24xx_io_desc)); |
266 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); | 255 | iotable_init(omap243x_io_desc, ARRAY_SIZE(omap243x_io_desc)); |
267 | _omap2_map_common_io(); | ||
268 | } | 256 | } |
269 | #endif | 257 | #endif |
270 | 258 | ||
@@ -272,7 +260,6 @@ void __init omap243x_map_common_io(void) | |||
272 | void __init omap34xx_map_common_io(void) | 260 | void __init omap34xx_map_common_io(void) |
273 | { | 261 | { |
274 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); | 262 | iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc)); |
275 | _omap2_map_common_io(); | ||
276 | } | 263 | } |
277 | #endif | 264 | #endif |
278 | 265 | ||
@@ -280,7 +267,6 @@ void __init omap34xx_map_common_io(void) | |||
280 | void __init omapti816x_map_common_io(void) | 267 | void __init omapti816x_map_common_io(void) |
281 | { | 268 | { |
282 | iotable_init(omapti816x_io_desc, ARRAY_SIZE(omapti816x_io_desc)); | 269 | iotable_init(omapti816x_io_desc, ARRAY_SIZE(omapti816x_io_desc)); |
283 | _omap2_map_common_io(); | ||
284 | } | 270 | } |
285 | #endif | 271 | #endif |
286 | 272 | ||
@@ -288,7 +274,6 @@ void __init omapti816x_map_common_io(void) | |||
288 | void __init omap44xx_map_common_io(void) | 274 | void __init omap44xx_map_common_io(void) |
289 | { | 275 | { |
290 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); | 276 | iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc)); |
291 | _omap2_map_common_io(); | ||
292 | } | 277 | } |
293 | #endif | 278 | #endif |
294 | 279 | ||
@@ -337,7 +322,6 @@ void __iomem *omap_irq_base; | |||
337 | static void __init omap_common_init_early(void) | 322 | static void __init omap_common_init_early(void) |
338 | { | 323 | { |
339 | omap2_check_revision(); | 324 | omap2_check_revision(); |
340 | omap_sram_init(); | ||
341 | } | 325 | } |
342 | 326 | ||
343 | static void __init omap_hwmod_init_postsetup(void) | 327 | static void __init omap_hwmod_init_postsetup(void) |
@@ -449,11 +433,12 @@ void __init omap4430_init_early(void) | |||
449 | void __init omap_sdrc_init(struct omap_sdrc_params *sdrc_cs0, | 433 | void __init omap_sdrc_init(struct omap_sdrc_params *sdrc_cs0, |
450 | struct omap_sdrc_params *sdrc_cs1) | 434 | struct omap_sdrc_params *sdrc_cs1) |
451 | { | 435 | { |
436 | omap_sram_init(); | ||
437 | |||
452 | if (cpu_is_omap24xx() || omap3_has_sdrc()) { | 438 | if (cpu_is_omap24xx() || omap3_has_sdrc()) { |
453 | omap2_sdrc_init(sdrc_cs0, sdrc_cs1); | 439 | omap2_sdrc_init(sdrc_cs0, sdrc_cs1); |
454 | _omap2_init_reprogram_sdrc(); | 440 | _omap2_init_reprogram_sdrc(); |
455 | } | 441 | } |
456 | |||
457 | } | 442 | } |
458 | 443 | ||
459 | /* | 444 | /* |