Linux Hardware Monitor development
 help / color / mirror / Atom feed
* [RFC PATCH v2 0/3] hwmon: asus-ec-sensors: MAXIMUS XI HERO Fan Extension Card
@ 2026-11-28 19:12 John den Heijer
  2026-11-28 19:12 ` [RFC PATCH v2 1/3] hwmon: (asus-ec-sensors) propagate EC read and selector errors John den Heijer
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: John den Heijer @ 2026-11-28 19:12 UTC (permalink / raw)
  To: linux-hwmon; +Cc: eugene.shalygin, linux

This is a request for design and safety feedback, not a request to merge
the series as-is. It adds opt-in monitoring of the three fan tachometers
and three thermistors on an ASUS Fan Extension Card attached to a ROG
MAXIMUS XI HERO (non-WiFi), BIOS 2004.

The pinned base is Guenter Roeck's hwmon-next at
8d0f79f49fb10c9f07fee6720551113272a1812b. It already contains the
MAXIMUS IX EXTREME selector-based extension fan path and EC 00:60..62
temperature descriptors, but does not select these sensors on XI HERO.

The BIOS 2004 image (SHA-256
034e6c688ca41cf448745398ce3ccfa184dfae217287ee7b72039498ff5aa812)
provides the following property and transaction evidence:

  EXT_FAN1/2/3: properties 0x060400e2/e3/e4; write EC 00:43 with
  selector 0x0a/0x0b/0x0c, then read high/low RPM bytes at 00:57/58.
  The getter checks EC 00:d4 on every call and performs first-use or
  lost-latch read-modify-writes d4 |= 0x80 and 89 |= 0x07.

  EXT_Sensor1/2/3: properties 0x06030032/34/36; after a firmware card
  property check, write EC 00:68 = 0x07 immediately before each read
  of 00:60/61/62. The exact meaning of 0x68 is not established.

BIOS 2203 has the same relevant fan mapping and getter control flow.
The BIOS presence property, IsEXTFanCardExist (0x06060050), reads the
EXTFanCard UEFI/Setup variable; we have not established a reliable live
electrical card-presence signal. Accordingly, the XI HERO extension
sensors remain disabled by default and are enabled only by an explicit
module parameter on the exact non-WiFi DMI name. The WiFi entry is not
changed. With the option enabled, the first read of any hwmon input may
trigger a full refresh and the extension setup writes, even if the user
did not request an EXT_* attribute.

Patch 1 changes generic EC/selector error propagation so a failed block
read cannot publish a partial sensor cache. This affects failure paths
on all supported boards, not only XI HERO. Patches 2 and 3 add the board
opt-in, RPM path and thermistor path. Patch 2 currently relies on the
restore/error path introduced by patch 1; we would rebase or reshape the
series if the generic change should be reviewed separately.

The new transactions use the driver's configured ACPI EC mutex, normally
\AMW0.ASMX on XI HERO. They do not add PWM, fan-control, NCT, direct
EC-port or WMI accesses. They do write the EC bank selector, the BIOS
observed d4/89 setup registers, the fan selector and 0x68. We do not
claim that these writes are harmless when the optional card is absent.

A different, locally maintained asus-ec-sensors module for Unraid 7.4.1
/ 6.18.64-Unraid has returned all six channels on a physical XI HERO
with the card installed, including after one reboot. The binaries and
some error/selector handling differ; that test is not a runtime test of
this upstream RFC. On the v1 base, x86_64 and i386 objects compiled with
W=1, an x86_64 module linked with modpost without diagnostics, and a
static comparison of 66 DMI names finds no default sensor-mask, family,
mutex or existing-descriptor change. We have not tested this RFC on
other boards or with the card absent.

Questions for maintainers:

1. Is a default-off, exact-DMI opt-in acceptable when firmware exposes
   only a Setup-variable-backed card property, or is another presence
   mechanism required before these EC writes can be accepted?
2. Should the driver preserve the BIOS first-use d4/89 writes even when
   d4 bit 7 is already set? We have not isolated their necessity and do
   not want to replace a working BIOS sequence with an untested shortcut.
3. Is reproducing the BIOS's 68=07 write before every thermistor read an
   acceptable basis while its bit semantics remain unknown? A separate
   BIOS Extension control initialization path also writes 68=07.
4. Would you prefer patch 1 as a separate bugfix before the board support,
   and what fault-path regression evidence would be useful?
5. Is the separate non-WiFi board profile and module parameter an
   appropriate interface, or should the board/card policy be expressed
   differently?

The series is intentionally an RFC. The three patches carry the
submitter-confirmed DCO sign-off. We welcome review of the card-presence
policy, register transactions and generic error handling before any
attempt to merge.

Changes since v1:
- Rebased on hwmon-next at Guenter's request. The resulting driver is
  byte-identical to the v1 driver.
- The archived v1 diffs contain wrapped lines. In particular, git
  reports corrupt patches for 2/3 and 3/3. The original diffs apply
  cleanly on this base.

v1: https://lore.kernel.org/linux-hwmon/CAP-m2G6VwPqTOZ_uQEAsWnb=j4yFj+_N0V33gOTL5kRYwwYbvg@mail.gmail.com/

John den Heijer (3):
  hwmon: (asus-ec-sensors) propagate EC read and selector errors
  hwmon: (asus-ec-sensors) add opt-in MAXIMUS XI HERO EXT fan RPM
  hwmon: (asus-ec-sensors) add MAXIMUS XI HERO EXT thermistors

 drivers/hwmon/asus-ec-sensors.c | 140 ++++++++++++++++++++++++++++----
 1 file changed, 122 insertions(+), 18 deletions(-)


base-commit: 8d0f79f49fb10c9f07fee6720551113272a1812b
-- 
2.54.0 (Apple Git-157)


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

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

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-28 19:12 [RFC PATCH v2 0/3] hwmon: asus-ec-sensors: MAXIMUS XI HERO Fan Extension Card John den Heijer
2026-11-28 19:12 ` [RFC PATCH v2 1/3] hwmon: (asus-ec-sensors) propagate EC read and selector errors John den Heijer
2026-11-28 19:17   ` sashiko-bot
2026-11-28 19:12 ` [RFC PATCH v2 2/3] hwmon: (asus-ec-sensors) add opt-in MAXIMUS XI HERO EXT fan RPM John den Heijer
2026-11-28 19:19   ` sashiko-bot
2026-11-28 19:12 ` [RFC PATCH v2 3/3] hwmon: (asus-ec-sensors) add MAXIMUS XI HERO EXT thermistors John den Heijer
2026-11-28 19:19 ` [RFC PATCH v2 0/3] hwmon: asus-ec-sensors: MAXIMUS XI HERO Fan Extension Card sashiko-bot

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