[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <700ca7dc-bf7f-4242-a64f-ab593aa78b9f@roeck-us.net>
Date: Sat, 17 Jan 2026 09:12:02 -0800
From: Guenter Roeck <linux@...ck-us.net>
To: leobannocloutier@...il.com
Cc: linux-hwmon@...r.kernel.org, linux-kernel@...r.kernel.org,
pali@...nel.org, Armin Wolf <W_Armin@....de>
Subject: Re: [PATCH v2 0/1] hwmon: (dell-smm) Add Dell G15 5510 to fan
control whitelist
On Fri, Jan 16, 2026 at 08:53:14PM -0500, leobannocloutier@...il.com wrote:
> > Please consult Documentation/process/submitting-patches.rst
> > and Documentation/hwmon/submitting-patches.rst before submitting patches.
>
> Thanks for the links to the documentation, I tried following it as much
> as I could, let me know if there's anything else I can improve.
Well, a start would be to actually follow the guidance provided, specifically
in Explicit In-Reply-To headers. It says:
"However, for a multi-patch series, it is generally
best to avoid using In-Reply-To: to link to older versions of the
series. This way multiple versions of the patch don't become an
unmanageable forest of references in email clients."
and to also follow the rest of the guidance. Since getting kind of tired
of having to explain this again and again, I submitted this header and the
actual patch to Google's Gemini AI, giving it the following directions.
"The patch in file patch.1, with added explanation in file patch.0, does not
adhere to the guidelines provided by linux/Documentation/process/submitting-patches.rst.
Suggest an alternate patch description.
"
Here is what it suggested:
hwmon: (dell-smm) Add Dell G15 5510 to fan control whitelist
On the Dell G15 5510, fans spin at maximum speed when AC power is
connected. This behavior has been observed as a regression in recent
kernels (v6.18+).
Add the Dell G15 5510 to the fan control whitelist to enable manual fan
control and resolve the issue. This model requires the same fan control
configuration as the Dell G15 5511.
Key Improvements:
* Imperative Mood: Changed "I copied and adopted..." to "Add the Dell G15 5510..." and "This enables...".
* Removed Personal Narrative: Removed references to "running a system upgrade" and "my personal laptop" to focus on the technical problem and solution.
* Descriptive Problem Statement: Clearly states the symptoms (fans at max speed on AC) and the context (regression since v6.18).
* Technical Justification: Explains that the 5510 uses the same configuration as the 5511, justifying the use of existing driver data.
* Conciseness: Follows the 75-character line wrap recommendation for the body.
Please take that as suggestion for future patches.
Your description and the updated description both suggest that this is a
regression. So the question is if that is indeed the case, and what may
have introduced that regression. Please confirm that this worked with
v6.17. Anyway, I asked Gemini:
"The patch suggests that the problem is a regression in v6.18 of the
linux kernel. Analyze changes to the driver since v6.17 of the Linux
kernel and identify the patch introducing the regression.
"
and here is what it tells me:
The analysis of changes to the dell-smm-hwmon driver between Linux kernel versions v6.17.8 and v6.18.4 reveals that the regression was introduced by the following commit:
Commit ID: 1c1658058c99bcfd3b2347e587a556986037f80a
Subject: hwmon: (dell-smm) Add support for automatic fan mode
Root Cause Analysis
1. New Heuristic: This commit introduced a heuristic that automatically exposes pwmX_enable sysfs attributes on Dell laptops even if they are not explicitly whitelisted. It does this whenever the detected maximum fan state is less than 3
(which is common, as many Dell BIOSes use states 0, 1, and 2).
2. Incorrect Mapping for G15 5510: For non-whitelisted machines, the driver maps the "Automatic" fan mode (value 2 written to pwmX_enable) to fan state 3.
3. Maximum Speed Issue: On the Dell G15 5510, fan state 3 is interpreted by the hardware/BIOS as "Turbo" or "Maximum Speed" rather than "Automatic BIOS control".
4. Regression Trigger: When the AC power cable is plugged in, system power management tools (like tlp, thermald, or desktop environment services) often attempt to reset the fan mode to "Auto". In v6.17.8, these attributes were hidden for
this model, so no action was taken. In v6.18.4, the attributes are visible, and the attempt to set them to "Auto" triggers the driver to set the fan to state 3, causing it to spin at maximum speed.
5. Confirmation: A follow-up commit (1e9cf600da98) specifically addresses an off-by-one error in the visibility logic introduced by this patch, further confirming it as the source of the behavioral changes in pwmX_enable.
Whitelisting the Dell G15 5510 (as proposed in the alternate patch description) correctly resolves this by instructing the driver to use the model-specific SMM commands (0x30a3 for manual and 0x31a3 for automatic) instead of the generic
state 3 heuristic.
Copying Armin. Armin - any comments ? I am concerned that your patch
changes behavior for an unknown number of systems. Adding whitelists
to address that on a per system basis seems wrong. Any suggestions ?
I'll apply this patch for now, but unless there is a better solution we
may end up having to revert commit 1c1658058c99 if some other system is
reported to be affected.
Thanks,
Guenter
>
> I tested manual_fan and auto_fan by using `sudo i8kctl mode0 manual`.
> Manual seems to bring back the expected behavior where the 2 fans follow
> the fan curve described in my i8kmon.conf, while automatic brings the 2
> fans to full speed.
>
> Link to v1:
> https://lore.kernel.org/linux-hwmon/20260114020108.83288-1-leobannocloutier@gmail.com/
>
> Leo Banno-Cloutier (1):
> hwmon: (dell-smm) Add Dell G15 5510 to fan control whitelist
>
> drivers/hwmon/dell-smm-hwmon.c | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> --
> 2.52.0
>
>
Powered by blists - more mailing lists