]> git.ipfire.org Git - thirdparty/openwrt.git/commit
realtek: add Hasivo MCU watchdog driver 23418/head
authorCarlo Szelinsky <github@szelinsky.de>
Mon, 18 May 2026 20:41:21 +0000 (22:41 +0200)
committerMarkus Stockhausen <markus.stockhausen@gmx.de>
Sun, 31 May 2026 08:57:26 +0000 (10:57 +0200)
commitd048137e85e1434ede70f48a91b6b4fe9b57eae1
tree0e4f16c8bec0329707a6e7de590a4a48e3232bed
parentc9406df91836b5c94a395b61ebe5c16e08e2c779
realtek: add Hasivo MCU watchdog driver

Add a watchdog driver for the external management MCU on Hasivo /
Horaco network switches, reachable over I2C. Without periodic
keepalive the MCU resets the board every ~3 minutes.

The driver arms the MCU at probe and registers a struct
watchdog_device with WDOG_HW_RUNNING so the watchdog core feeds the
chip via a kernel timer until userspace opens the watchdog node.
Timeout is fixed at 15s; the hardware threshold is baked into MCU
firmware and is not software-configurable.

The I2C address is supplied per-board in the device tree via the
`reg` property. The driver does not constrain or probe a specific
address. Known addresses across current Hasivo / Horaco silicon:

  - 0x6F: Hasivo S1300WP-8XGT-4S+, Hasivo F5800W-12S+,
          Horaco ZX-SW82TS-L2P (default / most common)
  - 0x6E: alternate Hasivo / Horaco variant

The driver, its device-tree binding and the Kconfig/Makefile wiring
are added to the kernel tree as a realtek target patch and exposed as
the kmod-hasivo-mcu-wdt KernelPackage. Keeping the binding in the
kernel tree lets dt_binding_check exercise it during the build and
makes the whole driver easy to drop once it lands upstream.

Tested on Hasivo S1300WP-8XGT-4S+ (RTL9313). Unbinding the driver
causes the MCU to power-cycle the board within ~15s.

Signed-off-by: Carlo Szelinsky <github@szelinsky.de>
Link: https://github.com/openwrt/openwrt/pull/23418
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
target/linux/realtek/modules.mk
target/linux/realtek/patches-6.18/810-add-hasivo-mcu-wdt.patch [new file with mode: 0644]
target/linux/realtek/rtl838x/config-6.18
target/linux/realtek/rtl839x/config-6.18
target/linux/realtek/rtl930x/config-6.18
target/linux/realtek/rtl930x_nand/config-6.18
target/linux/realtek/rtl931x/config-6.18
target/linux/realtek/rtl931x_nand/config-6.18