aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDoug Anderson <armlinux@m.disordat.com>2016-04-06 19:27:26 -0400
committerRussell King <rmk+kernel@armlinux.org.uk>2016-07-14 10:32:31 -0400
commit9f6f93543d473d656bdc5c94f567c7684e956e52 (patch)
tree77e162b07a7e405724b0ddd00201005687ce64f8
parent416bcf21591850cd12066b2f11655695118e6908 (diff)
ARM: 8560/1: errata: Workaround errata A12 825619 / A17 852421
The workaround for both errata is to set bit 24 in the diagnostic register. There are no known end-user bugs solved by fixing this errata, but the fix is trivial and it seems sane to apply it. The arguments for why this needs to be in the kernel are similar to the arugments made in the patch "Workaround errata A12 818325/852422 A17 852423". Signed-off-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--arch/arm/Kconfig18
-rw-r--r--arch/arm/mm/proc-v7.S11
2 files changed, 29 insertions, 0 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index ed275aa293e5..1be1022c21e8 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1210,6 +1210,24 @@ config ARM_ERRATA_821420
1210 one is in the shadow of a branch or abort, can lead to a 1210 one is in the shadow of a branch or abort, can lead to a
1211 deadlock when the VMOV instructions are issued out-of-order. 1211 deadlock when the VMOV instructions are issued out-of-order.
1212 1212
1213config ARM_ERRATA_825619
1214 bool "ARM errata: A12: DMB NSHST/ISHST mixed ... might cause deadlock"
1215 depends on CPU_V7
1216 help
1217 This option enables the workaround for the 825619 Cortex-A12
1218 (all revs) erratum. Within rare timing constraints, executing a
1219 DMB NSHST or DMB ISHST instruction followed by a mix of Cacheable
1220 and Device/Strongly-Ordered loads and stores might cause deadlock
1221
1222config ARM_ERRATA_852421
1223 bool "ARM errata: A17: DMB ST might fail to create order between stores"
1224 depends on CPU_V7
1225 help
1226 This option enables the workaround for the 852421 Cortex-A17
1227 (r1p0, r1p1, r1p2) erratum. Under very rare timing conditions,
1228 execution of a DMB ST instruction might fail to properly order
1229 stores from GroupA and stores from GroupB.
1230
1213config ARM_ERRATA_852423 1231config ARM_ERRATA_852423
1214 bool "ARM errata: A17: some seqs of opposed cond code instrs => deadlock or corruption" 1232 bool "ARM errata: A17: some seqs of opposed cond code instrs => deadlock or corruption"
1215 depends on CPU_V7 1233 depends on CPU_V7
diff --git a/arch/arm/mm/proc-v7.S b/arch/arm/mm/proc-v7.S
index eefc10ff8e7e..a7123b4e129d 100644
--- a/arch/arm/mm/proc-v7.S
+++ b/arch/arm/mm/proc-v7.S
@@ -373,9 +373,20 @@ __ca12_errata:
373 orr r10, r10, #1 << 1 @ set bit #1 373 orr r10, r10, #1 << 1 @ set bit #1
374 mcr p15, 0, r10, c15, c0, 2 @ write internal feature reg 374 mcr p15, 0, r10, c15, c0, 2 @ write internal feature reg
375#endif 375#endif
376#ifdef CONFIG_ARM_ERRATA_825619
377 mrc p15, 0, r10, c15, c0, 1 @ read diagnostic register
378 orr r10, r10, #1 << 24 @ set bit #24
379 mcr p15, 0, r10, c15, c0, 1 @ write diagnostic register
380#endif
376 b __errata_finish 381 b __errata_finish
377 382
378__ca17_errata: 383__ca17_errata:
384#ifdef CONFIG_ARM_ERRATA_852421
385 cmp r6, #0x12 @ only present up to r1p2
386 mrcle p15, 0, r10, c15, c0, 1 @ read diagnostic register
387 orrle r10, r10, #1 << 24 @ set bit #24
388 mcrle p15, 0, r10, c15, c0, 1 @ write diagnostic register
389#endif
379#ifdef CONFIG_ARM_ERRATA_852423 390#ifdef CONFIG_ARM_ERRATA_852423
380 cmp r6, #0x12 @ only present up to r1p2 391 cmp r6, #0x12 @ only present up to r1p2
381 mrcle p15, 0, r10, c15, c0, 1 @ read diagnostic register 392 mrcle p15, 0, r10, c15, c0, 1 @ read diagnostic register