Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

MIPS: ath79: fix system restart

This patch disables irq on reboot to fix hang issues that were observed
due to pending interrupts.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: Paul Burton <paul.burton@mips.com>
Patchwork: https://patchwork.linux-mips.org/patch/19913/
Cc: James Hogan <jhogan@kernel.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: linux-mips@linux-mips.org

authored by

Felix Fietkau and committed by
Paul Burton
f8a7bfe1 a08227a2

+2
+1
arch/mips/ath79/setup.c
··· 40 40 41 41 static void ath79_restart(char *command) 42 42 { 43 + local_irq_disable(); 43 44 ath79_device_reset_set(AR71XX_RESET_FULL_CHIP); 44 45 for (;;) 45 46 if (cpu_wait)
+1
arch/mips/include/asm/mach-ath79/ath79.h
··· 167 167 static inline void ath79_reset_wr(unsigned reg, u32 val) 168 168 { 169 169 __raw_writel(val, ath79_reset_base + reg); 170 + (void) __raw_readl(ath79_reset_base + reg); /* flush */ 170 171 } 171 172 172 173 static inline u32 ath79_reset_rr(unsigned reg)