bcm47xx_wdt.h 555 B

123456789101112131415161718192021222324252627
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef LINUX_BCM47XX_WDT_H_
  3. #define LINUX_BCM47XX_WDT_H_
  4. #include <linux/timer.h>
  5. #include <linux/types.h>
  6. #include <linux/watchdog.h>
  7. struct bcm47xx_wdt {
  8. u32 (*timer_set)(struct bcm47xx_wdt *, u32);
  9. u32 (*timer_set_ms)(struct bcm47xx_wdt *, u32);
  10. u32 max_timer_ms;
  11. void *driver_data;
  12. struct watchdog_device wdd;
  13. struct timer_list soft_timer;
  14. atomic_t soft_ticks;
  15. };
  16. static inline void *bcm47xx_wdt_get_drvdata(struct bcm47xx_wdt *wdt)
  17. {
  18. return wdt->driver_data;
  19. }
  20. #endif /* LINUX_BCM47XX_WDT_H_ */