Unable to stop watchdog

I wrote a simple program to start the watchdog in user space, following this post.

I’d like to stop the watchdog when the application ends. According to this link, I need to write V to the watchdog file before closing it.

For some reason, when I try to do it, the watchdog does not stop and the board reboots. Based on the code available on the link above, the Jetson Xavier NX supports the magic close char.

Try below command

Tegra WDT
    Disable
          echo 1 > /sys/kernel/debug/tegra_wdt/disable_wdt_reset
    Enable
          echo 0 > /sys/kernel/debug/tegra_wdt/disable_wdt_reset
 PMIC
    Normal state –
         Disable
           echo disable > /sys/devices/platform/7000d000.i2c/i2c-4/4-003c/max77620-wdt.5/watchdog_normal_state
         Enable
           echo enable > /sys/devices/platform/7000d000.i2c/i2c-4/4-003c/max77620-wdt.5/watchdog_normal_state
     LP0 –
         Disable
             echo disable > /sys/devices/platform/7000d000.i2c/i2c-4/4-003c/max77620-wdt.5/watchdog_suspend_state
         Enable
             echo enable > /sys/devices/platform/7000d000.i2c/i2c-4/4-003c/max77620-wdt.5/watchdog_suspend_state

These folders /sys/kernel/debug/tegra_wdt/ and /sys/devices/platform/7000d000.i2c/ do not seem to be there.

Check this for Xavier NX

echo 1 > /sys/kernel/debug/30c0000.watchdog/disable_dbg_reset
echo 1 > /sys/kernel/debug/30c0000.watchdog/disable_por_reset