bcm53xx: backport the latest 4.2 ARM BCM5302X patches
[openwrt/openwrt.git] / target / linux / bcm53xx / patches-3.18 / 063-ARM-BCM5301X-Ignore-another-BCM4709-specific-fault-c.patch
1 From 7eb68a2a0519a77b93184c695d4d293c92dc2286 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5@gmail.com>
3 Date: Wed, 11 Feb 2015 16:40:58 +0100
4 Subject: [PATCH] ARM: BCM5301X: Ignore another (BCM4709 specific) fault code
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 Broadcom ARM devices seem to generate some fault once per boot. We
10 already have an ignoring handler for BCM4707/BCM4708, but BCM4709
11 generates different code.
12
13 Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
14 Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
15 ---
16 arch/arm/mach-bcm/bcm_5301x.c | 9 +++++----
17 1 file changed, 5 insertions(+), 4 deletions(-)
18
19 diff --git a/arch/arm/mach-bcm/bcm_5301x.c b/arch/arm/mach-bcm/bcm_5301x.c
20 index e9bcbdb..7aef927 100644
21 --- a/arch/arm/mach-bcm/bcm_5301x.c
22 +++ b/arch/arm/mach-bcm/bcm_5301x.c
23 @@ -18,15 +18,16 @@ static bool first_fault = true;
24 static int bcm5301x_abort_handler(unsigned long addr, unsigned int fsr,
25 struct pt_regs *regs)
26 {
27 - if (fsr == 0x1c06 && first_fault) {
28 + if ((fsr == 0x1406 || fsr == 0x1c06) && first_fault) {
29 first_fault = false;
30
31 /*
32 - * These faults with code 0x1c06 happens for no good reason,
33 - * possibly left over from the CFE boot loader.
34 + * These faults with codes 0x1406 (BCM4709) or 0x1c06 happens
35 + * for no good reason, possibly left over from the CFE boot
36 + * loader.
37 */
38 pr_warn("External imprecise Data abort at addr=%#lx, fsr=%#x ignored.\n",
39 - addr, fsr);
40 + addr, fsr);
41
42 /* Returning non-zero causes fault display and panic */
43 return 0;
44 --
45 1.8.4.5
46