X86 platform drivers
 help / color / mirror / Atom feed
* [PATCH] platform/x86: thinkpad_acpi: Don't report non-present second fan on models with quirk
@ 2026-04-11 15:34 LevitatingBusinessMan (Rein Fernhout)
  2026-05-06 13:35 ` Ilpo Järvinen
  0 siblings, 1 reply; 2+ messages in thread
From: LevitatingBusinessMan (Rein Fernhout) @ 2026-04-11 15:34 UTC (permalink / raw)
  To: hmh
  Cc: mpearson-lenovo, platform-driver-x86, hansg,
	LevitatingBusinessMan (Rein Fernhout)

Some models report a second-fan with speed 65535 indicating that this fan is not present.

A previous fix (a10d50983f7be) disabled these fans.

However, the else branch still enables the fan on some models with a quirk enabled.

Namely the P15v Gen 1 has such a quirk, introduced in e8637dfca15e0.

Although it appears the P15 Gen 1 does have a second fan, the P15v Gen 1 does not (reporting speed 65535).

I think in all cases, this can be solved by never enabling the fan if it is detected and the reported speed reads 65535.

To do so, we only run the else branch if no fan was detected.
---
 drivers/platform/x86/lenovo/thinkpad_acpi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/platform/x86/lenovo/thinkpad_acpi.c b/drivers/platform/x86/lenovo/thinkpad_acpi.c
index 8982d92dfd97..282a0c54ce0c 100644
--- a/drivers/platform/x86/lenovo/thinkpad_acpi.c
+++ b/drivers/platform/x86/lenovo/thinkpad_acpi.c
@@ -8948,7 +8948,7 @@ static int __init fan_init(struct ibm_init_struct *iibm)
 				/* fan control not currently available for ns ECFW */
 				tp_features.second_fan_ctl = !fan_with_ns_addr;
 				pr_info("secondary fan control detected & enabled\n");
-			} else {
+			} else if (res < 0) {
 				/* Fan not auto-detected */
 				tp_features.second_fan = 0;
 				if (quirks & TPACPI_FAN_2FAN) {
-- 
2.53.0


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

end of thread, other threads:[~2026-05-06 13:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-11 15:34 [PATCH] platform/x86: thinkpad_acpi: Don't report non-present second fan on models with quirk LevitatingBusinessMan (Rein Fernhout)
2026-05-06 13:35 ` Ilpo Järvinen

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