diff options
author | Tomasz Figa <t.figa@samsung.com> | 2012-12-10 23:58:43 -0500 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2013-04-08 12:52:30 -0400 |
commit | 41de89860baf8e62fd74e83338058575398ad21f (patch) | |
tree | ac2a7b8d1dbf2a6161a30f86e90f9018702b8fe7 /arch | |
parent | bca28f8f6b93fc1fb000d8695e59266d307aceab (diff) |
ARM: EXYNOS: Add IO mapping for non-secure SYSRAM.
On TrustZone-enabled boards the non-secure SYSRAM is used for secondary
CPU bring-up, so add a mapping for it.
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-exynos/common.c | 35 | ||||
-rw-r--r-- | arch/arm/mach-exynos/include/mach/map.h | 3 | ||||
-rw-r--r-- | arch/arm/plat-samsung/include/plat/map-s5p.h | 1 |
3 files changed, 39 insertions, 0 deletions
diff --git a/arch/arm/mach-exynos/common.c b/arch/arm/mach-exynos/common.c index 02e35abd136b..b2bb2b70832b 100644 --- a/arch/arm/mach-exynos/common.c +++ b/arch/arm/mach-exynos/common.c | |||
@@ -232,6 +232,33 @@ static struct map_desc exynos4_iodesc1[] __initdata = { | |||
232 | }, | 232 | }, |
233 | }; | 233 | }; |
234 | 234 | ||
235 | static struct map_desc exynos4210_iodesc[] __initdata = { | ||
236 | { | ||
237 | .virtual = (unsigned long)S5P_VA_SYSRAM_NS, | ||
238 | .pfn = __phys_to_pfn(EXYNOS4210_PA_SYSRAM_NS), | ||
239 | .length = SZ_4K, | ||
240 | .type = MT_DEVICE, | ||
241 | }, | ||
242 | }; | ||
243 | |||
244 | static struct map_desc exynos4x12_iodesc[] __initdata = { | ||
245 | { | ||
246 | .virtual = (unsigned long)S5P_VA_SYSRAM_NS, | ||
247 | .pfn = __phys_to_pfn(EXYNOS4x12_PA_SYSRAM_NS), | ||
248 | .length = SZ_4K, | ||
249 | .type = MT_DEVICE, | ||
250 | }, | ||
251 | }; | ||
252 | |||
253 | static struct map_desc exynos5250_iodesc[] __initdata = { | ||
254 | { | ||
255 | .virtual = (unsigned long)S5P_VA_SYSRAM_NS, | ||
256 | .pfn = __phys_to_pfn(EXYNOS5250_PA_SYSRAM_NS), | ||
257 | .length = SZ_4K, | ||
258 | .type = MT_DEVICE, | ||
259 | }, | ||
260 | }; | ||
261 | |||
235 | static struct map_desc exynos5_iodesc[] __initdata = { | 262 | static struct map_desc exynos5_iodesc[] __initdata = { |
236 | { | 263 | { |
237 | .virtual = (unsigned long)S3C_VA_SYS, | 264 | .virtual = (unsigned long)S3C_VA_SYS, |
@@ -360,6 +387,11 @@ static void __init exynos4_map_io(void) | |||
360 | else | 387 | else |
361 | iotable_init(exynos4_iodesc1, ARRAY_SIZE(exynos4_iodesc1)); | 388 | iotable_init(exynos4_iodesc1, ARRAY_SIZE(exynos4_iodesc1)); |
362 | 389 | ||
390 | if (soc_is_exynos4210()) | ||
391 | iotable_init(exynos4210_iodesc, ARRAY_SIZE(exynos4210_iodesc)); | ||
392 | if (soc_is_exynos4212() || soc_is_exynos4412()) | ||
393 | iotable_init(exynos4x12_iodesc, ARRAY_SIZE(exynos4x12_iodesc)); | ||
394 | |||
363 | /* initialize device information early */ | 395 | /* initialize device information early */ |
364 | exynos4_default_sdhci0(); | 396 | exynos4_default_sdhci0(); |
365 | exynos4_default_sdhci1(); | 397 | exynos4_default_sdhci1(); |
@@ -392,6 +424,9 @@ static void __init exynos4_map_io(void) | |||
392 | static void __init exynos5_map_io(void) | 424 | static void __init exynos5_map_io(void) |
393 | { | 425 | { |
394 | iotable_init(exynos5_iodesc, ARRAY_SIZE(exynos5_iodesc)); | 426 | iotable_init(exynos5_iodesc, ARRAY_SIZE(exynos5_iodesc)); |
427 | |||
428 | if (soc_is_exynos5250()) | ||
429 | iotable_init(exynos5250_iodesc, ARRAY_SIZE(exynos5250_iodesc)); | ||
395 | } | 430 | } |
396 | 431 | ||
397 | static void __init exynos5440_map_io(void) | 432 | static void __init exynos5440_map_io(void) |
diff --git a/arch/arm/mach-exynos/include/mach/map.h b/arch/arm/mach-exynos/include/mach/map.h index 7f99b7b187d6..99e0a79f3b1f 100644 --- a/arch/arm/mach-exynos/include/mach/map.h +++ b/arch/arm/mach-exynos/include/mach/map.h | |||
@@ -26,6 +26,9 @@ | |||
26 | #define EXYNOS4_PA_SYSRAM0 0x02025000 | 26 | #define EXYNOS4_PA_SYSRAM0 0x02025000 |
27 | #define EXYNOS4_PA_SYSRAM1 0x02020000 | 27 | #define EXYNOS4_PA_SYSRAM1 0x02020000 |
28 | #define EXYNOS5_PA_SYSRAM 0x02020000 | 28 | #define EXYNOS5_PA_SYSRAM 0x02020000 |
29 | #define EXYNOS4210_PA_SYSRAM_NS 0x0203F000 | ||
30 | #define EXYNOS4x12_PA_SYSRAM_NS 0x0204F000 | ||
31 | #define EXYNOS5250_PA_SYSRAM_NS 0x0204F000 | ||
29 | 32 | ||
30 | #define EXYNOS4_PA_FIMC0 0x11800000 | 33 | #define EXYNOS4_PA_FIMC0 0x11800000 |
31 | #define EXYNOS4_PA_FIMC1 0x11810000 | 34 | #define EXYNOS4_PA_FIMC1 0x11810000 |
diff --git a/arch/arm/plat-samsung/include/plat/map-s5p.h b/arch/arm/plat-samsung/include/plat/map-s5p.h index c2d7bdae5891..c18678610bc0 100644 --- a/arch/arm/plat-samsung/include/plat/map-s5p.h +++ b/arch/arm/plat-samsung/include/plat/map-s5p.h | |||
@@ -22,6 +22,7 @@ | |||
22 | #define S5P_VA_GPIO3 S3C_ADDR(0x02280000) | 22 | #define S5P_VA_GPIO3 S3C_ADDR(0x02280000) |
23 | 23 | ||
24 | #define S5P_VA_SYSRAM S3C_ADDR(0x02400000) | 24 | #define S5P_VA_SYSRAM S3C_ADDR(0x02400000) |
25 | #define S5P_VA_SYSRAM_NS S3C_ADDR(0x02410000) | ||
25 | #define S5P_VA_DMC0 S3C_ADDR(0x02440000) | 26 | #define S5P_VA_DMC0 S3C_ADDR(0x02440000) |
26 | #define S5P_VA_DMC1 S3C_ADDR(0x02480000) | 27 | #define S5P_VA_DMC1 S3C_ADDR(0x02480000) |
27 | #define S5P_VA_SROMC S3C_ADDR(0x024C0000) | 28 | #define S5P_VA_SROMC S3C_ADDR(0x024C0000) |