Skip to contentSkip to conversation

qnap-mcu: add ts233 support

PATCH Applied Heiko Stuebner 3 participants 5 messages Jul 30, 2025 – Jul 31, 2025

Subsystems (3)
lore
Share & tools
lore

Heiko Stuebner

author maintainer
#0 lore raw

cover qnap-mcu: add ts233 support

For a better return on all the investigating I did into that MCU, I got myself a 2nd device - the 2-bay TS233 this time.

Add the necessary driver-data and compatible for it to the MCU.

Heiko Stuebner (2):
dt-bindings: mfd: qnap,ts433-mcu: add qnap,ts233-mcu compatible
mfd: qnap-mcu: add driver data for ts233 variant

 .../devicetree/bindings/mfd/qnap,ts433-mcu.yaml          | 1 +
 drivers/mfd/qnap-mcu.c                                   | 9 +++++++++
 2 files changed, 10 insertions(+)
Signature · 1 line
2.47.2
author maintainer
#1 lore raw

PATCH 1/2 dt-bindings: mfd: qnap,ts433-mcu: add qnap,ts233-mcu compatible

The same MCU is used on other devices of the series with a slightly different set of features, like the number of LEDs.

Add a compatible for the MCU used in the TS233 variant.

---
 Documentation/devicetree/bindings/mfd/qnap,ts433-mcu.yaml | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/mfd/qnap,ts433-mcu.yaml +1 -0
index 877078ac172f..fe9e06cfb933 100644
@@ -16,6 +16,7 @@ description:
 properties:
   compatible:
     enum:
+      - qnap,ts233-mcu
       - qnap,ts433-mcu
 
 patternProperties:
Signature · 1 line
2.47.2
maintainer Acked-by on v1 1/2
#2 lore raw

Re: [PATCH 1/2] dt-bindings: mfd: qnap,ts433-mcu: add qnap,ts233-mcu compatible

Quoted 10 lines · Heiko Stuebner

The same MCU is used on other devices of the series with a slightly different set of features, like the number of LEDs.

Add a compatible for the MCU used in the TS233 variant.

---
 Documentation/devicetree/bindings/mfd/qnap,ts433-mcu.yaml | 1 +
 1 file changed, 1 insertion(+)
author maintainer
#3 lore raw

PATCH 2/2 mfd: qnap-mcu: add driver data for ts233 variant

In reply to Heiko Stuebner

Add the TS233 compatible and affiliated driver data to qnap-mcu. The TS233 is mostly similar to the TS433, except not having any of the PCIe components, so there are only 2 drives.

The fan pwm-limits from the vendor-configuration also are the same as for the ts433 variant.

---
 drivers/mfd/qnap-mcu.c | 9 +++++++++
 1 file changed, 9 insertions(+)
drivers/mfd/qnap-mcu.c +9 -0
index 223156b98b79..6ed020206e55 100644
@@ -329,6 +329,14 @@ static int qnap_mcu_power_off(struct sys_off_data *data)
 	return NOTIFY_DONE;
 }
 
+static const struct qnap_mcu_variant qnap_ts233_mcu = {
+	.baud_rate = 115200,
+	.num_drives = 2,
+	.fan_pwm_min = 51,  /* Specified in original model.conf */
+	.fan_pwm_max = 255,
+	.usb_led = true,
+};
+
 static const struct qnap_mcu_variant qnap_ts433_mcu = {
 	.baud_rate = 115200,
 	.num_drives = 4,
@@ -405,6 +413,7 @@ static int qnap_mcu_probe(struct serdev_device *serdev)
 }
 
 static const struct of_device_id qnap_mcu_dt_ids[] = {
+	{ .compatible = "qnap,ts233-mcu", .data = &qnap_ts233_mcu },
 	{ .compatible = "qnap,ts433-mcu", .data = &qnap_ts433_mcu },
 	{ /* sentinel */ }
 };
Signature · 1 line
2.47.2
maintainer Applied
#4 lore raw
In reply to Heiko Stuebner
Quoted 10 lines · Heiko Stuebner

For a better return on all the investigating I did into that MCU, I got myself a 2nd device - the 2-bay TS233 this time.

Add the necessary driver-data and compatible for it to the MCU.

Heiko Stuebner (2):
dt-bindings: mfd: qnap,ts433-mcu: add qnap,ts233-mcu compatible
mfd: qnap-mcu: add driver data for ts233 variant

[...]

Applied, thanks!

[1/2] dt-bindings: mfd: qnap,ts433-mcu: add qnap,ts233-mcu compatible

      commit: 38dc76168a92a1e8fb28a901607ac24c4778141c
[2/2] mfd: qnap-mcu: add driver data for ts233 variant
      commit: 5f1edbae853329b8a6e637fed0f7202727aec545

--
Lee Jones [李琼斯]