WDT, which started operating in BootROM, is stopped by the process immediately after the start of U-Boot.
Therefore, if you want to use WDT, you need to re-setup WDT after U-Boot.
When WDT is re-set up in U-Boot, it can be used by adding the definition of #define CONFIG_HW_WATCHDOG.
(Example of change)
Target file: uboot-socfpga/include/configs/socfpga_arria10.h
/*
* L4 Watchdog
*/
#if 1 /*(CONFIG_PRELOADER_WATCHDOG_ENABLE == 1) ★ Change to "#if 1" */
# define CONFIG_HW_WATCHDOG
#define CONFIG_HW_WATCHDOG_TIMEOUT_MS (2000)
#define CONFIG_DESIGNWARE_WATCHDOG
#define CONFIG_DW_WDT_BASE SOCFPGA_L4WD0_ADDRESS
/* Clocks source frequency to watchdog timer */
/* Preloader and U-Boot need to know the clock source frequency from handoff*/
# define CONFIG_DW_WDT_CLOCK_KHZ (50000000 / 1000)/*(CONFIG_HPS_CLK_OSC1_HZ / 1000) ★ Specify l4_sys_free_clk frequency (50MHz --> 50000KHz) */
#endif /* CONFIG_PRELOADER_WATCHDOG_ENABLE */
**Note: The definition of CONFIG_DW_WDT_CLOCK_KHZ as well as CONFIG_HW_WATCHDOG needs to be modified.
(The original definition uses CONFIG_HPS_CLK_OSC1_HZ, but there is no corresponding definition, resulting in a build error. Correct the content)
--------------------
Category: SoC
Tools: SoC EDS
Device: Arria® 10