[PATCH v1 6/7] zorro: warp mfd: expose the fan duty cycle
From: Paolo Pisati
Date: Wed Nov 11 2026 - 11:46:27 EST
The diagnostic frame also reports the fan drive as a percentage.
Expose it as fanspeedpercent.
Signed-off-by: Paolo Pisati <p.pisati@xxxxxxxxx>
---
Documentation/ABI/testing/sysfs-driver-warp-mfd | 7 +++++++
drivers/zorro/warp-mfd.c | 2 ++
2 files changed, 9 insertions(+)
diff --git a/Documentation/ABI/testing/sysfs-driver-warp-mfd b/Documentation/ABI/testing/sysfs-driver-warp-mfd
index fec712b8b9b0..a8213affb153 100644
--- a/Documentation/ABI/testing/sysfs-driver-warp-mfd
+++ b/Documentation/ABI/testing/sysfs-driver-warp-mfd
@@ -33,3 +33,10 @@ Contact: Paolo Pisati <p.pisati@xxxxxxxxx>
Description:
(RO) Voltages in volts, with two decimals: vbatt is the backup
battery, vcc5v the 5 V rail.
+
+What: /sys/bus/zorro/devices/zorro<N>/fanspeedpercent
+Date: November 2026
+KernelVersion: 7.5
+Contact: Paolo Pisati <p.pisati@xxxxxxxxx>
+Description:
+ (RO) Fan drive, as a percentage.
diff --git a/drivers/zorro/warp-mfd.c b/drivers/zorro/warp-mfd.c
index d407c786d44b..a438faeaa232 100644
--- a/drivers/zorro/warp-mfd.c
+++ b/drivers/zorro/warp-mfd.c
@@ -303,6 +303,7 @@ out: \
static DEVICE_ATTR_RO(name)
warp_config_string_attr(boardname, board_name);
+warp_config_uint_attr(fanspeedpercent, fan_percent, "%u");
warp_config_uint_attr(fmwver, fmw_ver, "%04X");
warp_config_uint_attr(hwver, hw_ver, "%04X");
/* board sensors: volts to 2 decimals, temperatures to 1, as WarpDiag shows them */
@@ -315,6 +316,7 @@ warp_config_sensor_attr(vcc5v, vcc5v, 2);
static struct attribute *warp_attrs[] = {
/* RO attr */
&dev_attr_boardname.attr,
+ &dev_attr_fanspeedpercent.attr,
&dev_attr_fmwver.attr,
&dev_attr_hwver.attr,
&dev_attr_t60int.attr,
--
2.43.0