diff options
author | Arnd Bergmann <arnd@arndb.de> | 2011-10-08 15:47:06 -0400 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2011-10-08 15:47:06 -0400 |
commit | a3849a4c038a21075a0bc7eaf37f65a93976d10c (patch) | |
tree | 77e1148cdd719856dcf1692f8d9167691347d17b /arch/arm/mach-ux500 | |
parent | 71f2c153755442c05d15cd025484f676a5f3541f (diff) | |
parent | 1bf6d2c1bb23533af6930581cc39b74685bc29de (diff) |
Merge branch 'stericsson/fixes' into next/cleanup
Conflicts:
arch/arm/mach-ux500/cpu.c
Diffstat (limited to 'arch/arm/mach-ux500')
-rw-r--r-- | arch/arm/mach-ux500/Kconfig | 1 | ||||
-rw-r--r-- | arch/arm/mach-ux500/cache-l2x0.c | 25 |
2 files changed, 25 insertions, 1 deletions
diff --git a/arch/arm/mach-ux500/Kconfig b/arch/arm/mach-ux500/Kconfig index 4210cb434dbc..a3e0c8692f0d 100644 --- a/arch/arm/mach-ux500/Kconfig +++ b/arch/arm/mach-ux500/Kconfig | |||
@@ -6,6 +6,7 @@ config UX500_SOC_COMMON | |||
6 | select ARM_GIC | 6 | select ARM_GIC |
7 | select HAS_MTU | 7 | select HAS_MTU |
8 | select ARM_ERRATA_753970 | 8 | select ARM_ERRATA_753970 |
9 | select ARM_ERRATA_754322 | ||
9 | 10 | ||
10 | menu "Ux500 SoC" | 11 | menu "Ux500 SoC" |
11 | 12 | ||
diff --git a/arch/arm/mach-ux500/cache-l2x0.c b/arch/arm/mach-ux500/cache-l2x0.c index 9d09e4d013b9..122ddde00ba7 100644 --- a/arch/arm/mach-ux500/cache-l2x0.c +++ b/arch/arm/mach-ux500/cache-l2x0.c | |||
@@ -50,7 +50,27 @@ static void ux500_l2x0_inv_all(void) | |||
50 | ux500_cache_sync(); | 50 | ux500_cache_sync(); |
51 | } | 51 | } |
52 | 52 | ||
53 | static int ux500_l2x0_init(void) | 53 | static int __init ux500_l2x0_unlock(void) |
54 | { | ||
55 | int i; | ||
56 | |||
57 | /* | ||
58 | * Unlock Data and Instruction Lock if locked. Ux500 U-Boot versions | ||
59 | * apparently locks both caches before jumping to the kernel. The | ||
60 | * l2x0 core will not touch the unlock registers if the l2x0 is | ||
61 | * already enabled, so we do it right here instead. The PL310 has | ||
62 | * 8 sets of registers, one per possible CPU. | ||
63 | */ | ||
64 | for (i = 0; i < 8; i++) { | ||
65 | writel_relaxed(0x0, l2x0_base + L2X0_LOCKDOWN_WAY_D_BASE + | ||
66 | i * L2X0_LOCKDOWN_STRIDE); | ||
67 | writel_relaxed(0x0, l2x0_base + L2X0_LOCKDOWN_WAY_I_BASE + | ||
68 | i * L2X0_LOCKDOWN_STRIDE); | ||
69 | } | ||
70 | return 0; | ||
71 | } | ||
72 | |||
73 | static int __init ux500_l2x0_init(void) | ||
54 | { | 74 | { |
55 | if (cpu_is_u5500()) | 75 | if (cpu_is_u5500()) |
56 | l2x0_base = __io_address(U5500_L2CC_BASE); | 76 | l2x0_base = __io_address(U5500_L2CC_BASE); |
@@ -59,6 +79,9 @@ static int ux500_l2x0_init(void) | |||
59 | else | 79 | else |
60 | ux500_unknown_soc(); | 80 | ux500_unknown_soc(); |
61 | 81 | ||
82 | /* Unlock before init */ | ||
83 | ux500_l2x0_unlock(); | ||
84 | |||
62 | /* 64KB way size, 8 way associativity, force WA */ | 85 | /* 64KB way size, 8 way associativity, force WA */ |
63 | l2x0_init(l2x0_base, 0x3e060000, 0xc0000fff); | 86 | l2x0_init(l2x0_base, 0x3e060000, 0xc0000fff); |
64 | 87 | ||