Commit a68256074f4239008c6d5c936bc0f8857f3d1b8a

Authored by Christophe Leroy
Committed by Tom Rini
1 parent 12fdbbe860

watchdog: mpc8xx: Revert the 8xx watchdog back to CONFIG_HW_WATCHDOG

Commit f3729ba6e7b2 ("watchdog: mpc8xx_wdt: Watchdog driver and macros
cleanup") switched the watchdog to CONFIG_WATCHDOG. But this is not
compatible with the 8xx because it starts the watchdog HW timer at
reset and must be serviced from the very beginning including while
U-boot is executed in the firmware before relocation in RAM.

Select CONFIG_HW_WATCHDOG and make hw_watchdog_reset() visible.

Meanwhile, finalise the cleanup of arch/powerpc/cpu/mpc8xx/Kconfig by
removing the lines put in comment in that commit, and also remove
again the selection of CONFIG_MPC8xx_WATCHDOG which was removed by
that commit and brought back by mistake by commit b3134ffbd944
("watchdog: Kconfig: Sort entry alphabetically")

Note that there was an 'imply WATCHDOG' in the original commit but
it disappeared in the Kconfig alphabetical sorting, so no need to
remove it here.

Fixes: f3729ba6e7b2 ("watchdog: mpc8xx_wdt: Watchdog driver and macros cleanup")
Fixes: b3134ffbd944 ("watchdog: Kconfig: Sort entry alphabetically")
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Cc: Stefan Roese <sr@denx.de>
Cc: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Stefan Roese <sr@denx.de>

Showing 3 changed files with 2 additions and 6 deletions Side-by-side Diff

arch/powerpc/cpu/mpc8xx/Kconfig
... ... @@ -25,10 +25,6 @@
25 25  
26 26 endchoice
27 27  
28   -#config MPC8xx_WATCHDOG
29   -# bool "Watchdog"
30   -# select HW_WATCHDOG
31   -
32 28 config 8xx_GCLK_FREQ
33 29 int "CPU GCLK Frequency"
34 30  
drivers/watchdog/Kconfig
... ... @@ -118,7 +118,7 @@
118 118 config WDT_MPC8xx
119 119 bool "MPC8xx watchdog timer support"
120 120 depends on WDT && MPC8xx
121   - select CONFIG_MPC8xx_WATCHDOG
  121 + select HW_WATCHDOG
122 122 help
123 123 Select this to enable mpc8xx watchdog timer
124 124  
drivers/watchdog/mpc8xx_wdt.c
... ... @@ -10,7 +10,7 @@
10 10 #include <asm/cpm_8xx.h>
11 11 #include <asm/io.h>
12 12  
13   -static void hw_watchdog_reset(void)
  13 +void hw_watchdog_reset(void)
14 14 {
15 15 immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR;
16 16