watchdog: Implement generic watchdog_reset() version
[project/bcm63xx/u-boot.git] / board / CZ.NIC / turris_mox / turris_mox.c
index 96cb9c7e5c6e2543e7084b7228c7f374b63c3384..8a4872343b65d634edbc3751889e4372324716f4 100644 (file)
@@ -119,41 +119,11 @@ int board_fix_fdt(void *blob)
 }
 #endif
 
-#ifdef CONFIG_WDT_ARMADA_37XX
-static struct udevice *watchdog_dev __attribute__((section(".data"))) = NULL;
-
-void watchdog_reset(void)
-{
-       static ulong next_reset;
-       ulong now;
-
-       if (!watchdog_dev)
-               return;
-
-       now = timer_get_us();
-
-       /* Do not reset the watchdog too often */
-       if (now > next_reset) {
-               wdt_reset(watchdog_dev);
-               next_reset = now + 100000;
-       }
-}
-#endif
-
 int board_init(void)
 {
        /* address of boot parameters */
        gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
 
-#ifdef CONFIG_WDT_ARMADA_37XX
-       if (uclass_get_device(UCLASS_WDT, 0, &watchdog_dev)) {
-               printf("Cannot find Armada 3720 watchdog!\n");
-       } else {
-               printf("Enabling Armada 3720 watchdog (3 minutes timeout).\n");
-               wdt_start(watchdog_dev, 180000, 0);
-       }
-#endif
-
        return 0;
 }