diff --git a/boards/nxp/frdm_mcxa166/board.c b/boards/nxp/frdm_mcxa166/board.c index 86909b65599..1c0ffff6c07 100644 --- a/boards/nxp/frdm_mcxa166/board.c +++ b/boards/nxp/frdm_mcxa166/board.c @@ -153,6 +153,11 @@ void board_early_init_hook(void) #if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(edma0)) RESET_ReleasePeripheralReset(kDMA0_RST_SHIFT_RSTn); #endif + +#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(wwdt0)) + CLOCK_SetClockDiv(kCLOCK_DivWWDT0, 1u); +#endif + /* Set SystemCoreClock variable. */ SystemCoreClock = CLOCK_INIT_CORE_CLOCK; } diff --git a/boards/nxp/frdm_mcxa166/frdm_mcxa166.dts b/boards/nxp/frdm_mcxa166/frdm_mcxa166.dts index 3a07ecb2fa5..0305e2b5c41 100644 --- a/boards/nxp/frdm_mcxa166/frdm_mcxa166.dts +++ b/boards/nxp/frdm_mcxa166/frdm_mcxa166.dts @@ -20,6 +20,7 @@ led2 = &red_led; sw0 = &user_button_2; sw1 = &user_button_3; + watchdog0 = &wwdt0; }; chosen { @@ -140,3 +141,7 @@ }; }; }; + +&wwdt0 { + status = "okay"; +}; diff --git a/boards/nxp/frdm_mcxa166/frdm_mcxa166.yaml b/boards/nxp/frdm_mcxa166/frdm_mcxa166.yaml index 93ce63ee9bd..90ed90d1117 100644 --- a/boards/nxp/frdm_mcxa166/frdm_mcxa166.yaml +++ b/boards/nxp/frdm_mcxa166/frdm_mcxa166.yaml @@ -17,4 +17,5 @@ supported: - gpio - uart - flash + - watchdog vendor: nxp diff --git a/boards/nxp/frdm_mcxa276/board.c b/boards/nxp/frdm_mcxa276/board.c index 86909b65599..1c0ffff6c07 100644 --- a/boards/nxp/frdm_mcxa276/board.c +++ b/boards/nxp/frdm_mcxa276/board.c @@ -153,6 +153,11 @@ void board_early_init_hook(void) #if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(edma0)) RESET_ReleasePeripheralReset(kDMA0_RST_SHIFT_RSTn); #endif + +#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(wwdt0)) + CLOCK_SetClockDiv(kCLOCK_DivWWDT0, 1u); +#endif + /* Set SystemCoreClock variable. */ SystemCoreClock = CLOCK_INIT_CORE_CLOCK; } diff --git a/boards/nxp/frdm_mcxa276/frdm_mcxa276.dts b/boards/nxp/frdm_mcxa276/frdm_mcxa276.dts index 0ac367bbf6f..2858f54c094 100644 --- a/boards/nxp/frdm_mcxa276/frdm_mcxa276.dts +++ b/boards/nxp/frdm_mcxa276/frdm_mcxa276.dts @@ -20,6 +20,7 @@ led2 = &red_led; sw0 = &user_button_2; sw1 = &user_button_3; + watchdog0 = &wwdt0; }; chosen { @@ -140,3 +141,7 @@ }; }; }; + +&wwdt0 { + status = "okay"; +}; diff --git a/boards/nxp/frdm_mcxa276/frdm_mcxa276.yaml b/boards/nxp/frdm_mcxa276/frdm_mcxa276.yaml index 065b8c89164..72c1be60f4e 100644 --- a/boards/nxp/frdm_mcxa276/frdm_mcxa276.yaml +++ b/boards/nxp/frdm_mcxa276/frdm_mcxa276.yaml @@ -17,4 +17,5 @@ supported: - gpio - uart - flash + - watchdog vendor: nxp diff --git a/dts/arm/nxp/nxp_mcxa166.dtsi b/dts/arm/nxp/nxp_mcxa166.dtsi index 9029d9f7e55..11c1618991e 100644 --- a/dts/arm/nxp/nxp_mcxa166.dtsi +++ b/dts/arm/nxp/nxp_mcxa166.dtsi @@ -214,6 +214,14 @@ no-error-irq; status = "disabled"; }; + + wwdt0: watchdog@4000c000 { + compatible = "nxp,lpc-wwdt"; + reg = <0x4000c000 0x1000>; + interrupts = <60 0>; + status = "disabled"; + clk-divider = <1>; + }; }; }; diff --git a/dts/arm/nxp/nxp_mcxa276.dtsi b/dts/arm/nxp/nxp_mcxa276.dtsi index 9029d9f7e55..11c1618991e 100644 --- a/dts/arm/nxp/nxp_mcxa276.dtsi +++ b/dts/arm/nxp/nxp_mcxa276.dtsi @@ -214,6 +214,14 @@ no-error-irq; status = "disabled"; }; + + wwdt0: watchdog@4000c000 { + compatible = "nxp,lpc-wwdt"; + reg = <0x4000c000 0x1000>; + interrupts = <60 0>; + status = "disabled"; + clk-divider = <1>; + }; }; };