public inbox for linux-hwmon@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/1]
@ 2026-03-19 13:29 Sergio Melas
  2026-03-19 13:29 ` [PATCH 1/1] hwmon: (yogafan) Add universal Lenovo Yoga/Legion fan driver Sergio Melas
  2026-03-19 19:37 ` [PATCH 0/1] Guenter Roeck
  0 siblings, 2 replies; 5+ messages in thread
From: Sergio Melas @ 2026-03-19 13:29 UTC (permalink / raw)
  To: linux-hwmon, groeck, sergiomelas; +Cc: platform-driver-x86, jdelvare

This patch introduces a new driver for Lenovo Yoga, Legion, and IdeaPad
laptops that report fan speeds via ACPI.

The driver addresses the "jumpy" and low-resolution RPM data common in
Lenovo Embedded Controllers by implementing a passive First-Order Lag
filter with slew-rate limiting (RLLag).

Technical Validation:
- Verified via physical tachometer and FOPTD (First-Order Plus Time Delay)
  identification to ensure the filter constant (TAU_MS) matches hardware inertia.
- Stress-tested through multiple S3 (Suspend) and S4 (Hibernate) cycles.
- Verified 0.0% memory drift over 4+ hours of active monitoring.
- Compatible with KDE Plasma 6 System Monitor and standard hwmon tools.

The implementation is "passive," calculating filter state transitions 
only upon userspace read requests. This ensures physical model consistency 
without the power overhead of background kernel threads.

Changes since v1:
- Updated MODULE_LICENSE to "GPL".
- Removed background worker/kthread; implemented a passive update strategy.
- Added Documentation/hwmon/yoga_fan.rst.
- Added universal ACPI path probing for up to 8 fans (FANS, FA2S, FAN0).

Sergio Melas (1):
  hwmon: (yogafan) Add universal Lenovo Yoga/Legion fan driver

 Documentation/hwmon/yoga_fan.rst    |  36 +++++
 auto_compile_rust_lenovo_drivers.sh | 196 -----------------------
 drivers/hwmon/Kconfig               |  14 ++
 drivers/hwmon/Makefile              |   1 +
 drivers/hwmon/yoga_fan.c            | 237 ++++++++++++++++++++++++++++
 5 files changed, 288 insertions(+), 196 deletions(-)
 create mode 100644 Documentation/hwmon/yoga_fan.rst
 delete mode 100755 auto_compile_rust_lenovo_drivers.sh
 create mode 100644 drivers/hwmon/yoga_fan.c

-- 
2.53.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-03-19 19:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-19 13:29 [PATCH 0/1] Sergio Melas
2026-03-19 13:29 ` [PATCH 1/1] hwmon: (yogafan) Add universal Lenovo Yoga/Legion fan driver Sergio Melas
2026-03-19 15:59   ` Guenter Roeck
2026-03-19 17:03     ` Guenter Roeck
2026-03-19 19:37 ` [PATCH 0/1] Guenter Roeck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox