-
ZynqMP platform device-tree can be found in https://github.com/Xilinx/device-tree-xlnx/blob/xlnx_rel_v2021.2/device_tree/data/kernel_dtsi/2021.2/zynqmp/zynqmp.dtsi#L1043-L1051
zynqmp.dtsi# timeout-sec value is set to 10s in 2018.2 and below release and 60s in 2018.3 and later release. watchdog0: watchdog@fd4d0000 { compatible = "cdns,wdt-r1p2"; status = disabled; interrupt-parent = <&gic>; interrupts = <0 113 1>; reg = <0x0 0xfd4d0000 0x1000>; timeout-sec = <60>; };
-
Modify the device tree source in <plnx-proj-root>/project-spec/meta-user/recipes-bsp/device-tree/files/system-user.dtsi as below and rebuild your project.
system-user.dtsi&watchdog0 { status = "okay"; };
-
If user want the watchdog to trigger a software reset/reboot upon time out then add "reset-on-timeout" in device tree node. Software reset is handled in PMU firmware for Zynq UltraScale+ MPSoC/RFSoC so you need add PMU firmware elf packaged as part of BOOT.bin
system-user.dtsi&watchdog0 { status = "okay"; reset-on-timeout; timeout-sec = <10>; };
-
For 2017.1 or later PetaLinux ENABLE_EM needs to be enabled from PMUFW, For more details refer PetaLinux Yocto Tips and PMU Firmware#PMUFWBuildFlags
# For 2017.4 and below PetaLinux/Yocto release only $ vim <plnx-proj-root>/project-spec/meta-user/recipes-bsp/pmu/pmu-firmware_%.bbappend #For v2018.1 to v2020.2 PetaLinux/Yocto releases only $ vim <plnx-proj-root>/project-spec/meta-user/recipes-bsp/pmu-firmware/pmu-firmware_%.bbappend # For v2021.1 PetaLinux/Yocto releases only $ vim <plnx-proj-root>/project-spec/meta-user/recipes-bsp/emebdeddedsw/pmu-firmware_%.bbappend # For v2021.2 and later PetaLinux/Yocto releases only $ vim <plnx-proj-root>/project-spec/meta-user/recipes-bsp/embeddedsw/pmu-firmware_%.bbappend
pmu-firmware_%.bbappend# pmu-firmware_%.bbappend content YAML_COMPILER_FLAGS_append = " -DENABLE_EM -DENABLE_SCHEDULER"