From: "Kurt Borja" <kuurtb@gmail.com>
To: "Rong Zhang" <i@rong.moe>,
"Mark Pearson" <mpearson-lenovo@squebb.ca>,
"Derek J. Clark" <derekjohn.clark@gmail.com>,
"Armin Wolf" <W_Armin@gmx.de>, "Hans de Goede" <hansg@kernel.org>,
"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
Cc: "Guenter Roeck" <linux@roeck-us.net>,
<platform-driver-x86@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <linux-hwmon@vger.kernel.org>
Subject: Re: [PATCH v9 7/7] platform/x86: lenovo-wmi-other: Add HWMON for fan reporting/tuning
Date: Wed, 14 Jan 2026 19:16:30 -0500 [thread overview]
Message-ID: <DFOQB6DGBKBZ.39JQKPB7XDSJG@gmail.com> (raw)
In-Reply-To: <20260114122745.986699-8-i@rong.moe>
Hi Rong,
On Wed Jan 14, 2026 at 7:27 AM -05, Rong Zhang wrote:
> Register an HWMON device for fan reporting/tuning according to
> Capability Data 00 (capdata00) and Fan Test Data (capdata_fan) provided
> by lenovo-wmi-capdata. The corresponding HWMON nodes are:
>
> - fanX_enable: enable/disable the fan (tunable)
> - fanX_input: current RPM
> - fanX_max: maximum RPM
> - fanX_min: minimum RPM
> - fanX_target: target RPM (tunable)
>
> Information from capdata00 and capdata_fan are used to control the
> visibility and constraints of HWMON attributes. Fan info from capdata00
> is collected on bind, while fan info from capdata_fan is collected in a
> callback. Once all fan info is collected, register the HWMON device.
>
> Signed-off-by: Rong Zhang <i@rong.moe>
> Reviewed-by: Derek J. Clark <derekjohn.clark@gmail.com>
> ---
...
> diff --git a/Documentation/wmi/devices/lenovo-wmi-other.rst b/Documentation/wmi/devices/lenovo-wmi-other.rst
> index 821282e07d93c..bd1d733ff286d 100644
> --- a/Documentation/wmi/devices/lenovo-wmi-other.rst
> +++ b/Documentation/wmi/devices/lenovo-wmi-other.rst
> @@ -31,6 +31,8 @@ under the following path:
>
> /sys/class/firmware-attributes/lenovo-wmi-other/attributes/<attribute>/
>
> +Additionally, this driver also exports attributes to HWMON.
> +
> LENOVO_CAPABILITY_DATA_00
> -------------------------
>
> @@ -39,6 +41,11 @@ WMI GUID ``362A3AFE-3D96-4665-8530-96DAD5BB300E``
> The LENOVO_CAPABILITY_DATA_00 interface provides various information that
> does not rely on the gamezone thermal mode.
>
> +The following HWMON attributes are implemented:
> + - fanX_enable: enable/disable the fan (tunable)
I was testing this series and I'm a bit confused about fanX_enable.
Judging by this comment and also by taking a quick look at the code, it
looks like writting 0 to this attribute disables the fan.
This is however (per hwmon ABI documentation [1]) not how this attribute
should work. IIUC, it is intended for devices which can disable the fan
sensor, not the actual fan.
I fail to see how this feature is useful and I also find it dangerous
for this to be exposed by default, considering the same could be
achieved with the relaxed module parameter, which at least tells the
user to be careful.
Apologies if I missed some previous discussion on this.
[1] https://elixir.bootlin.com/linux/v6.19-rc5/source/Documentation/ABI/testing/sysfs-class-hwmon#L279
--
Thanks,
~ Kurt
next prev parent reply other threads:[~2026-01-15 0:16 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-14 12:27 [PATCH v9 0/7] platform/x86: lenovo-wmi-{capdata,other}: Add HWMON for fan speed Rong Zhang
2026-01-14 12:27 ` [PATCH v9 1/7] platform/x86: lenovo-wmi-helpers: Convert returned buffer into u32 Rong Zhang
2026-01-14 12:27 ` [PATCH v9 2/7] platform/x86: Rename lenovo-wmi-capdata01 to lenovo-wmi-capdata Rong Zhang
2026-01-14 12:27 ` [PATCH v9 3/7] platform/x86: lenovo-wmi-{capdata,other}: Support multiple Capability Data Rong Zhang
2026-01-14 12:27 ` [PATCH v9 4/7] platform/x86: lenovo-wmi-capdata: Add support for Capability Data 00 Rong Zhang
2026-01-14 12:27 ` [PATCH v9 5/7] platform/x86: lenovo-wmi-capdata: Add support for Fan Test Data Rong Zhang
2026-01-14 12:27 ` [PATCH v9 6/7] platform/x86: lenovo-wmi-capdata: Wire up " Rong Zhang
2026-01-14 12:27 ` [PATCH v9 7/7] platform/x86: lenovo-wmi-other: Add HWMON for fan reporting/tuning Rong Zhang
2026-01-15 0:16 ` Kurt Borja [this message]
2026-01-15 13:03 ` Rong Zhang
2026-01-15 13:58 ` Kurt Borja
2026-01-15 16:57 ` Rong Zhang
2026-01-15 17:45 ` Derek J. Clark
2026-01-15 18:19 ` Kurt Borja
2026-01-16 14:01 ` Rong Zhang
2026-01-15 19:09 ` Kurt Borja
2026-01-16 14:18 ` Rong Zhang
2026-01-16 17:17 ` Kurt Borja
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DFOQB6DGBKBZ.39JQKPB7XDSJG@gmail.com \
--to=kuurtb@gmail.com \
--cc=W_Armin@gmx.de \
--cc=derekjohn.clark@gmail.com \
--cc=hansg@kernel.org \
--cc=i@rong.moe \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=mpearson-lenovo@squebb.ca \
--cc=platform-driver-x86@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox