diff --git a/boards/arm/npcm400f_evb/npcm400f_evb.dts b/boards/arm/npcm400f_evb/npcm400f_evb.dts index 406d841bbabe78..614ae23f8aea68 100644 --- a/boards/arm/npcm400f_evb/npcm400f_evb.dts +++ b/boards/arm/npcm400f_evb/npcm400f_evb.dts @@ -65,6 +65,10 @@ current-speed = <115200>; }; +&twd0 { + status = "okay"; +}; + &peci0 { status = "okay"; pinctrl-0 = <&pinctrl_peci0_default>; diff --git a/drivers/watchdog/wdt_npcm4xx.c b/drivers/watchdog/wdt_npcm4xx.c index cfed19012cebf2..208d3ed68a7272 100644 --- a/drivers/watchdog/wdt_npcm4xx.c +++ b/drivers/watchdog/wdt_npcm4xx.c @@ -359,8 +359,11 @@ static const struct wdt_driver_api wdt_npcm4xx_driver_api = { .feed = wdt_npcm4xx_feed, }; -DEVICE_DT_INST_DEFINE(0, wdt_npcm4xx_init, NULL, - &wdt_npcm4xx_data_0, &wdt_npcm4xx_cfg_0, - PRE_KERNEL_1, - CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, - &wdt_npcm4xx_driver_api); +#define NPCM4XX_WDT_INIT(inst) \ + DEVICE_DT_INST_DEFINE(inst, wdt_npcm4xx_init, NULL, \ + &wdt_npcm4xx_data_##inst, &wdt_npcm4xx_cfg_##inst, \ + PRE_KERNEL_1, \ + CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, \ + &wdt_npcm4xx_driver_api); + +DT_INST_FOREACH_STATUS_OKAY(NPCM4XX_WDT_INIT)