sunxi: Watchdog reboot fails on Allwinner R40 after Linux boot

Fabio Estevam festevam at gmail.com
Sun May 24 05:41:41 PDT 2026


Hi,

I am seeing a reboot failure on an Allwinner R40-based board
(Boardcon EMA40i) running mainline Linux v6.18 or also 7.1.0-rc4-next-20260522.
This board hasn't been upstreamed yet, but I plan to do so soon.

The board reboots correctly from U-Boot 2026.04 using the sunxi watchdog,
but Linux fails to reboot even when programming the watchdog
registers with the exact same values used by U-Boot.

The board hangs with:

[ 10.736509] reboot: Restarting system

The watchdog node is:

    wdt: watchdog at 1c20c90 {
            compatible = "allwinner,sun4i-a10-wdt";
            reg = <0x01c20c90 0x10>;
            interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>;
            clocks = <&osc24M>;
    };

The hardware watchdog appears correctly:

[ 0.178494] sunxi-wdt 1c20c90.watchdog: Watchdog enabled (timeout=16
sec, nowayout=0)

I instrumented U-Boot and confirmed reboot goes through
drivers/watchdog/sunxi_wdt.c().

The final register state before a successful reboot in U-Boot is:

ctrl = 0x00000001
cfg = 0x00000003
mode = 0x00000003

and the board immediately resets.

However, under Linux, even direct MMIO writes do not reboot
the board:

devmem 0x01c20c94 32 0x00000003
devmem 0x01c20c90 32 0x00000001

No reset occurs.

I also tested:

- clk_ignore_unused
- removing the watchdog DT node entirely
- nosmp
- maxcpus=1
- psci=off

No change.

I compared:

- Watchdog registers
- CCU registers
- PRCM/RTC regions
- AXP22x PMIC registers

between U-Boot and Linux, and did not find an obvious difference that
explains the failure.

The board hardware connects the R40 RESET/AP-RESET signal to
the AXP22x PWROK input.

The PMIC power-off register works correctly from Linux:

i2cset -f -y 0 0x34 0x32 0x80

but this powers off the board instead of rebooting it.

Has anyone seen similar reboot failures on R40/sun8i platforms,
or is there any known erratum/workaround related to the watchdog
reset propagation after Linux runtime initialization?

Thanks,

Fabio Estevam



More information about the linux-arm-kernel mailing list