Commit graph

528 commits

Author SHA1 Message Date
Muhammed Asif
e452c05026 drivers: watchdog: microchip: watchdog g1 driver
- Adds watchdog g1 driver for microchip devices

Signed-off-by: Muhammed Asif <muhammed.asif@microchip.com>
2026-01-12 11:54:08 +01:00
Ruibin Chang
0671dc7925 drivers/wdt/it8xxx2: support setting time interval of warning msg
Add the config to support that warning message time
interval can be set.

We also find that printing all the warning messages
takes about 50ms on Chromebook. Therefore, we increase
the default time to 100ms to leave some time for EC to run
non-print instructions.

Signed-off-by: Ruibin Chang <Ruibin.Chang@ite.com.tw>
2026-01-08 09:49:28 +01:00
Holt Sun
8cb5b7dd58 drivers: watchdog: wdt_mcux_wwdt: reject callback without warning IRQ
The WWDT callback is only invoked from the warning interrupt path.
If CONFIG_WDT_MCUX_WWDT_WARNING_INTERRUPT_CFG is 0, the warning
interrupt is effectively disabled, so a configured callback would
never fire.
Return -ENOTSUP and log an error when a callback is provided
without enabling the warning interrupt, to avoid a silent no-op.

Signed-off-by: Holt Sun <holt.sun@nxp.com>
2025-12-27 21:00:57 +00:00
Holt Sun
8b365a3e2c drivers: watchdog: wdt_mcux_wwdt: fix window calculation.
Correct the WWDT window value calculation and add proper
range validation.

The window value was incorrectly set to the minimum timeout value.
Per hardware specification, it should be calculated as:
  windowValue = timeoutValue - min_window_ticks

Also add:
- MAX_TIMEOUT boundary checks
- Validation before value assignment

Signed-off-by: Holt Sun <holt.sun@nxp.com>
2025-12-27 21:00:57 +00:00
Sreeram Tatapudi
0a06f5b91a dts: bindings: Drop cat1 from the infineon binding files
Drop cat1 from the binding files to enable reuse by other
category devices as well.

Fixes #99174

Signed-off-by: Sreeram Tatapudi <sreeram.praveen@infineon.com>
2025-12-17 13:58:09 -05:00
Sylvio Alves
f8d2e00a0e includes: remove duplicated entries in zephyr-tree
Remove duplicated #include directives within the same
preprocessor scope across the Zephyr tree.

Duplicates inside different #ifdef branches are preserved
as they may be intentional.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2025-12-17 13:57:38 -05:00
Sylvio Alves
b7b32944fc drivers: espressif: move ISRs into IRAM area
Most of Espressif drivers ISRs are already running in IRAM area, except
those in this PR. Move ISRs accordingly so we avoid any
interrupt miss when cache is disabled.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2025-12-15 07:27:10 -05:00
Qingsong Gou
de66e05602 drivers: watchdog: sf32lb: fix return errors
Fix watchdog driver return error

Signed-off-by: Qingsong Gou <gouqs@hotmail.com>
2025-12-12 10:30:15 +01:00
Sreeram Tatapudi
5ecf248ba3 drivers: infineon: Drop cat1 from the files names
Drop cat1 from the file names to enable reuse by other
category devices as well

Signed-off-by: Sreeram Tatapudi <sreeram.praveen@infineon.com>
2025-12-07 21:19:38 -05:00
Yves Wang
9d76a637f9 drivers: watchdog: cop: ignore unused parameter
In install timeout api, the cfg parameter does not make sense to cop, we
can ignore it rather than return an error code to keep forward
compatibility.

Signed-off-by: Yves Wang <zhengjia.wang@nxp.com>
2025-12-06 07:12:45 -05:00
Julien Racki
086b873667 drivers: watchdog: Add the support of the IWDG Early Wakeup
Add the support of the IWDG early wakeup.
Gives the possibility for the user to set a
callback that will be called before an IWDG reset.

Signed-off-by: Julien Racki <julien.racki-ext@st.com>
2025-12-04 17:12:08 -05:00
Julien Racki
d3baaac688 drivers: watchdog: Add Kconfig option for the IWDG Early Wakeup
Add a Kconfig option that is enabled if the soc's
IWDG support early wakeup.

Signed-off-by: Julien Racki <julien.racki-ext@st.com>
2025-12-04 17:12:08 -05:00
Michał Stasiak
60892a30a7 drivers: watchdog: wdt_nrfx: return expected error
According to API docs, wdt_disable() should return
EFAULT when called too early. Adjusted driver.

Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
2025-12-03 09:13:24 -05:00
Martin Hoff
ff3637bf83 soc: silabs: siwx91x: enabled clock control by default for siwx91x soc
Enable clock control by default for siwx91x SoCs. Moreover, most
drivers for siwx91x soc depend on clock control, but didn't declare
it.

Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
2025-12-02 15:18:53 -05:00
Sai Santhosh Malae
d83740f2d8 drivers: watchdog: siwx91x: Fix pause in sleep
The watchdog timer on SiWx91x devices is designed to
pause during deep-sleep and resume after wakeup.
However, an incorrect check in`wdt_setup` was
preventing this intended behavior. This patch removes
the check, restoring the correct pause-in-sleep
functionality.

Signed-off-by: Sai Santhosh Malae <Santhosh.Malae@silabs.com>
2025-12-01 11:10:39 +01:00
cyliang tw
780f260efd drivers: watchdog: Fix Numaker driver bug in test suite
NuMaker watchdog control register is write-once after power-on
or reset. Thus, the control registeris written in the setup
function and the disable function only disables IRQ.

Signed-off-by: cyliang tw <cyliang@nuvoton.com>
2025-12-01 11:10:18 +01:00
James Torres
d30d7c29f3 drivers: watchdog: stm32 wwdg: remove floats to reduce footprint
On STM boards without an FPU (like nucleo_f091rc) the WWDG driver
requires 4K more of flash than the IWDG due to the use of floating
point math. Fixed it by refactoring to use integer math.
Reduced sample build ROM size from 24848 B to 21620 B on
nucleo_f091rc.

Signed-off-by: James Torres <jamesktorres2022@gmail.com>
2025-11-28 17:24:26 +00:00
Nikodem Kastelik
ad1e5ac253 nordic: update and align to nrfx 4.0.1
New nrfx release contains major rework of nrfx drivers
instantiation making it easier to integrate with dts nodes.
Now, nrfx driver instances can no longer be `const`
because they contain driver runtime state.
Additionally, all nrfx drivers return `errno` error codes
instead of deprecated `nrfx_err_t`.

Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
2025-11-27 14:45:17 +01:00
Yves Wang
ec7b99a855 drivers: watchdog: Make SWT compatible with hal_nxp
Avoid multiple declarations of SWT macros.
No need to log error for redundant watchdog disable.

Signed-off-by: Yves Wang <zhengjia.wang@nxp.com>
2025-11-21 10:09:59 +02:00
Josuah Demangeon
30950b888d style: drivers: sort Kconfig and CMake includes
Use the "zephyr-keep-sorted-start/stop" comment to have CI check
the alphabetical order of includes, to help reducing the chance
of conflicts while contributing drivers.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2025-11-17 13:48:03 -05:00
Etienne Carriere
b0ccb2295f drivers: stm32: use STM32_CLOCK_INFO_BY_NAME() and friends
Use STM32_CLOCK_INFO(), STM32_DT_INST_CLOCK_INFO(),
STM32_CLOCK_INFO_BY_NAME() and STM32_DT_INST_CLOCK_INFO_BY_NAME()
helper macros in STM32 drivers.

Using these macros ensure the clock division factor is properly
populated according to DT information. Prior these changes some
drivers only got the bus and bits position information and missed
the clock division information which is fine only when this division
factor information is 0.

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
2025-11-14 15:26:17 +02:00
Bill Waters
b35a32b8ae drivers: watchdog: add support for Infineon PSE84 device
Update the driver to support the PSE84 device

Signed-off-by: Bill Waters <bill.waters@infineon.com>
2025-10-24 23:07:28 +03:00
Aksel Skauge Mellbye
440755bd9e soc: silabs: Move Kconfig symbols for HAL selection to HAL
The Kconfig symbols for selecting HAL content should be part
of the HAL module integration, not defined by the SoC. Split the
symbols between the Series 0/1 Gecko HAL and Series 2 SiSDK HAL
when moving them.

For now, the Series 0/1 HAL symbols retain their name, while new
names consistent with the symbols already defined in the module
integration layer are used for the Series 2 HAL.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-10-22 09:03:15 +02:00
Quang Le
0611b01ca3 drivers: watchdog: Initial support for RZ/A3UL, N2L, T2M
Add Watchdog driver support for Renesas RZ/A3UL, N2L, T2M

Signed-off-by: Quang Le <quang.le.eb@bp.renesas.com>
Signed-off-by: Tien Nguyen <tien.nguyen.zg@renesas.com>
2025-10-16 17:16:19 +03:00
Qingsong Gou
bcc4689cd0 drivers: watchdog: add watchdog driver for sf32lb platform
Add initial watchdog driver for SF32LB platform

Signed-off-by: Qingsong Gou <gouqs@hotmail.com>
2025-10-15 17:38:09 -04:00
Yves Wang
1f9e39752a drivers: watchdog: wdog32: add delay before init
WDOG32 requires at least 2.5 periods of wdog clock after start up or
before reconfig.

Signed-off-by: Yves Wang <zhengjia.wang@nxp.com>
2025-10-13 18:14:00 -04:00
Yves Wang
b1b32bfc3d drivers: watchdog: wdog32: format source code
Format code with clang format.

Signed-off-by: Yves Wang <zhengjia.wang@nxp.com>
2025-10-13 18:14:00 -04:00
Sang Tran
7b9fd54052 drivers: watchdog: Support Renesas RX independent watchdog timer driver
Add initial support for independent watchdog driver for Renesas RX
with r_iwdt_rx RDP HAL

Signed-off-by: Sang Tran <sang.tran.jc@renesas.com>
2025-10-13 09:33:35 -04:00
Jiafei Pan
8e0486d291 drivers: watchdog: wdog32: add imx9352 support
On i.MX 93 platform, no need to clear interrupt flags, otherwise it
will not trigger reset.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Signed-off-by: Joe Zhou <zhongcai.zhou@nxp.com>
2025-10-06 20:17:50 -04:00
Jiafei Pan
9f6a74506f drivers: watchdog: wdog32: add MMIO mapping support
Added MMIO mapping support in order to support on Cortex-A Core.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-10-06 20:17:50 -04:00
Declan Snyder
570b445a61 drivers: Convert to use SPI macro without delay parameters
Convert all drivers and other consumers to use SPI macros without the
delay parameters.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-10-01 14:39:36 +03:00
Alexandre Rey
9291bac573 drivers: cop: add support of WDT_DISABLE_AT_BOOT
Add support for CONFIG_WDT_DISABLE_AT_BOOT Kconfig option.

Signed-off-by: Alexandre Rey <alx.rey@icloud.com>
2025-09-20 11:08:45 +02:00
Alexandre Rey
d571f90183 drivers: cop: add NXP cop driver
Port NXP cop driver to Zephyr

Signed-off-by: Alexandre Rey <alx.rey@icloud.com>
2025-09-20 11:08:45 +02:00
Yurii Lozynskyi
c09edc10fc drivers: watchdog: Shift watchdog to pdl
Shift ifx_cat1 watchdog driver to using pdl instead of hal calls

Signed-off-by: Yurii Lozynskyi <yurii.lozynskyi@infineon.com>
2025-09-06 18:16:55 -04:00
Luc BEAUFILS
d31f0138ad drivers: wdt_iwdg_stm32.c: freeze watchdog in debug mode for mp2x SoCs
The IWDG4 is on the APB3 bus on STM32MP2x SoCs. When the system is
in debug mode, the watchdog should be frozen to prevent it from
expiring and resetting the system during debugging sessions.

Signed-off-by: Luc BEAUFILS <luc.beaufils@savoirfairelinux.com>
2025-09-02 15:53:41 +02:00
Luc BEAUFILS
43b63b13e6 drivers: wdt_wwdg_stm32: freeze watchdog in debug mode for mp2x SoCs
Like the H7x series, the MP2x series has a WWDG1 peripheral in the APB3
bus. The MP2 has the same LL function to freeze the watchdog in debug
mode.

Signed-off-by: Luc BEAUFILS <luc.beaufils@savoirfairelinux.com>
2025-09-02 15:53:41 +02:00
Aksel Skauge Mellbye
3f7e614da6 drivers: watchdog: gecko: Fix API corner cases
Properly return the correct error codes when the watchdog API
is misused. Fail timeout install if WDT_FLAG_RESET_CPU_CORE is
set, a watchdog reset will at a minimum cause a soft reset of
the entire SoC.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-08-28 00:40:04 +02:00
Raffael Rostagno
1bd2734991 drivers: wdt: esp32h2: Add support
Add WDT support for ESP32-H2.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2025-08-26 22:07:36 +02:00
Yves Wang
201f70bfa9 drivers: watchdog: Make clock divider optional
Some SoCs did not provide ewm clock divider

Signed-off-by: Yves Wang <zhengjia.wang@nxp.com>
2025-08-22 09:45:18 +02:00
Francois Ramu
c32b481413 drivers: watchdog: stm32 wwdg check callback before calling
Check that the callback function exists before calling it
inside the ISR.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2025-08-18 13:07:00 +02:00
Lucien Zhao
8f94c91c5b drivers: watchdog: wdt_nxp_ewm.c: add clk_sel feature for ewm IP
emw clk designed on RT1180 can be chosen by CLKCTRL register,
add code to get sel from dts and configure it in driver.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-08-08 11:53:18 +03:00
Khoa Nguyen
3aa72e4e9e drivers: Update p_context for all Renesas drivers
The p_context no longer has the const type, so all
Renesas-supported drivers need to be updated accordingly.

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2025-08-08 11:52:13 +03:00
Ayush Singh
15377632c0 drivers: watchdog: Add ti rti driver
- This driver is used in k3 generation CPUs from TI.
- Does not support callbacks right now.

Signed-off-by: Ayush Singh <ayush@beagleboard.org>
2025-08-04 11:50:20 +01:00
Alvis Sun
5b1d16dd6f drivers: wdt: npcx: add wdt driver support for npck3
Enables the extended Watchdog Timer driver for npck3.

Signed-off-by: Alvis Sun <yfsun@nuvoton.com>
Signed-off-by: Mulin Chao <mlchao@nuvoton.com>
2025-07-19 15:36:47 -04:00
Hao Luo
e6f986f907 drivers: watchdog: bugfix for ambiq wdt clk select
This commit fixed the watchdog clock select error in
ambiq driver.

Signed-off-by: Hao Luo <hluo@ambiq.com>
2025-07-19 13:49:29 -04:00
Declan Snyder
efdd8580ca soc: nxp: Flatten MCX SOCs
Turn MCX series into families.

Reasoning:
 1. The MCX SOCs are quite different from each other and having them all
    under one family in the HWMv2 hierarchy is fruitless because there
    are so many differences that it is confusing to try to introduce
    family-level code and configs since they would each only apply to a
    subset of the series. There is almost nothing that can be shared
    between all of them. Which is why there are comments in the MCX
    family files saying not to put anything in them. This is a technical
    waste.
 2. Therefore, turning all of them into families is almost 0 effort and
    makes sense. It will allow these different types of MCX to be
    further subdivided into series in the future as the MCX portfolio
    expands and such division will be necessary as new SOCs within each
    letter family are released.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-07-19 13:25:29 -04:00
Harini T
e343379510 drivers: watchdog: Add Xilinx Window Watchdog driver support
Xilinx Window Watchdog driver uses window watchdog mode. Window watchdog
timer(WWDT) contains closed(first) and open(second) window with 32bit
width each. Write to the watchdog timer within predefined window periods
of time. This means a period that is not too soon and a period that is
not too late. The WWDT has to be restarted within the open window time.
If the software tries to restart WWDT outside of open window time
period, it generates a SoC reset.

Signed-off-by: Harini T <harini.t@amd.com>
2025-07-19 10:00:33 +02:00
David Leach
a132ebfe17 drivers: watchdog: Add enableWait setting for wdt_mcux_imx_wdog
When WDT_OPT_PAUSE_IN_SLEEP option is passed in set enableWait flag
in addition to the enableStop.

Fixes #86437

Signed-off-by: David Leach <david.leach@nxp.com>
2025-07-03 11:57:17 -05:00
Pieter De Gendt
f38527035a drivers: watchdog: Place device APIs in linker sections
Use DEVICE_API macro to place driver API instances into a linker section.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-06-27 10:09:32 -05:00
Steven Chang
03227c3520 drivers: watchdog: watchdog driver
Add watchdog driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00