1
2
3
4
5
6
7
8#include <linux/of_platform.h>
9#include <asm/hardware/cache-l2x0.h>
10
11#include <asm/mach/arch.h>
12#include <asm/siginfo.h>
13#include <asm/signal.h>
14
15
16static bool first_fault = true;
17
18static int bcm5301x_abort_handler(unsigned long addr, unsigned int fsr,
19 struct pt_regs *regs)
20{
21 if (fsr == 0x1c06 && first_fault) {
22 first_fault = false;
23
24
25
26
27
28 pr_warn("External imprecise Data abort at addr=%#lx, fsr=%#x ignored.\n",
29 addr, fsr);
30
31
32 return 0;
33 }
34
35
36 return 1;
37}
38
39static void __init bcm5301x_init_early(void)
40{
41
42 hook_fault_code(16 + 6, bcm5301x_abort_handler, SIGBUS, BUS_OBJERR,
43 "imprecise external abort");
44}
45
46static const char __initconst *bcm5301x_dt_compat[] = {
47 "brcm,bcm4708",
48 NULL,
49};
50
51DT_MACHINE_START(BCM5301X, "BCM5301X")
52 .l2c_aux_val = 0,
53 .l2c_aux_mask = ~0,
54 .init_early = bcm5301x_init_early,
55 .dt_compat = bcm5301x_dt_compat,
56MACHINE_END
57