1.. SPDX-License-Identifier: GPL-2.0+: 2 3wdt command 4============ 5 6Synopsis 7-------- 8 9:: 10 11 wdt list 12 wdt dev [<name>] 13 wdt start <timeout_ms> [flags] 14 wdt stop 15 wdt reset 16 wdt expirer [flags] 17 18Description 19----------- 20 21The wdt command is used to control watchdog timers. 22 23The 'wdt list' command shows a list of all watchdog devices. 24 25The 'wdt dev' command called without argument shows the current watchdog device. 26The current device is set when passing the name of the device as argument. 27 28The 'wdt start' command starts the current watchdog timer. 29 30The 'wdt stop' command stops the current watchdog timer. 31 32The 'wdt reset' command resets the current watchdog timer without stopping it. 33 34The 'wdt expire' command let's the current watchdog timer expire immediately. 35This will lead to a reset. 36 37name 38 name of the watchdog device 39 40timeout_ms 41 timeout interval in milliseconds 42 43flags 44 unsigned long value passed to the driver. The usage is driver specific. 45 The value is ignored by most drivers. 46 47Example 48------- 49 50:: 51 52 => wdt dev 53 No watchdog timer device set! 54 => wdt list 55 watchdog@1c20ca0 (sunxi_wdt) 56 => wdt dev watchdog@1c20ca0 57 => wdt dev 58 dev: watchdog@1c20ca0 59 => wdt start 3000 60 => wdt reset 61 => wdt stop 62 => wdt expire 63 64 U-Boot SPL 2022.04-rc3 (Mar 25 2022 - 13:48:33 +0000) 65 66 In the example above '(sunxi_wdt)' refers to the driver for the watchdog 67 device. 68 69Configuration 70------------- 71 72The command is only available if CONFIG_CMD_WDT=y. 73 74Return value 75------------ 76 77The return value $? is 0 if the command succeeds, 1 upon failure. 78