watchdog: qcom: fix kernel panic due to external abort on non-linefetch
Subsystems (2)
PATCH 1/1 watchdog: qcom: fix kernel panic due to external abort on non-linefetch
This patch fixes a off-by-one in the "watchdog: qcom: add option for standalone watchdog not in timer block" patch that causes the following panic on boot:
Quoted 16 lines
Unhandled fault: external abort on non-linefetch (
0x1008) at0xc8874002pgd =c0204000
[c8874002] *pgd=87806811, *pte=0b017653, *ppte=0b017453Internal error: : 1008 [#1] SMP ARM CPU: 2 PID: 1 Comm: swapper/0 Not tainted 4.8.6 #0 Hardware name: Generic DT based system PC is at 0xc02222f4 LR is at 0x1 pc : [<c02222f4>] lr : [<00000001>] psr: 00000113sp :
c782fc98ip : 00000003 fp : 00000000
r10: 00000004 r9 :c782e000r8 :c04ab98c
r7 : 00000001 r6 :c8874002r5 :c782fe00r4 : 00000002 r3 : 00000000 r2 :c782fe00r1 : 00100000 r0 :c8874002
Flags: nzcv IRQs on FIQs on ModeSVC_32ISA ARM Segment none
Control:10c5387dTable:8020406aDAC: 00000051 Process swapper/0 (pid: 1, stack limit =0xc782e210)
Quoted 2 lines
Stack: (0xc782fc98 to 0xc7830000)[...]
The WDT_STS (status) needs to be translated via wdt_addr as well.
--- drivers/watchdog/qcom-wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/watchdog/qcom-wdt.c +1 -1
@@ -209,7 +209,7 @@ static int qcom_wdt_probe(struct platform_device *pdev) wdt->wdd.parent = &pdev->dev; wdt->layout = regs; -if (readl (wdt->base +WDT_STS ) &1 ) +if (readl (wdt_addr (wdt,WDT_STS )) &1 ) wdt->wdd.bootstatus =WDIOF_CARDRESET ;/*
Signature · 1 line
2.10.2
Quoted 23 lines · Christian Lamparter
This patch fixes a off-by-one in the "watchdog: qcom: add option for standalone watchdog not in timer block" patch that causes the following panic on boot:
Quoted 16 lines
Unhandled fault: external abort on non-linefetch (
0x1008) at0xc8874002pgd =c0204000
[c8874002] *pgd=87806811, *pte=0b017653, *ppte=0b017453Internal error: : 1008 [#1] SMP ARM CPU: 2 PID: 1 Comm: swapper/0 Not tainted 4.8.6 #0 Hardware name: Generic DT based system PC is at 0xc02222f4 LR is at 0x1 pc : [<c02222f4>] lr : [<00000001>] psr: 00000113sp :
c782fc98ip : 00000003 fp : 00000000
r10: 00000004 r9 :c782e000r8 :c04ab98c
r7 : 00000001 r6 :c8874002r5 :c782fe00r4 : 00000002 r3 : 00000000 r2 :c782fe00r1 : 00100000 r0 :c8874002
Flags: nzcv IRQs on FIQs on ModeSVC_32ISA ARM Segment none
Control:10c5387dTable:8020406aDAC: 00000051 Process swapper/0 (pid: 1, stack limit =0xc782e210)Quoted 2 lines
Stack: (0xc782fc98 to 0xc7830000)[...]
Quoted 5 lines
The
WDT_STS(status) needs to be translated viawdt_addras well.Fixes f0d9d0f4b44a ("watchdog: qcom: add option for standalone watchdog not in timer block")Cc [email protected] # 4.8Signed-off-by Christian Lamparter <[email protected]>
Quoted 18 lines
--- drivers/watchdog/qcom-wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/watchdog/qcom-wdt.c +1
-1@@ -209,7 +209,7 @@ static int qcom_wdt_probe(struct platform_device *pdev) wdt->wdd.parent = &pdev->dev; wdt->layout = regs; -if (readl (wdt->base +WDT_STS ) &1 ) +if (readl (wdt_addr (wdt,WDT_STS )) &1 ) wdt->wdd.bootstatus =WDIOF_CARDRESET ;/*