Skip to contentSkip to conversation

platform/x86: thinkpad_acpi: Add more ThinkPads with non-standard reg address for fan

PATCH In review Vishnu Sankar 4 participants 5 messages Feb 28, 2024 – Mar 4, 2024 x86 platform drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 platform/x86: thinkpad_acpi: Add more ThinkPads with non-standard reg address for fan

Add more ThinkPads with non-standard register addresses to read fan values.

ThinkPads added are L13 Yoga Gen1, X13 Yoga Gen1, L380, L390, 11e Gen5 GL, 11e Gen5 GL-R, 11e Gen5 KL-Y.

---
 drivers/platform/x86/thinkpad_acpi.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/platform/x86/thinkpad_acpi.c +7 -0
index 5ecd9d33250d..23b2abe44a5a 100644
@@ -8767,6 +8767,13 @@ static const struct tpacpi_quirk fan_quirk_table[] __initconst = {
 	TPACPI_Q_LNV3('N', '3', '7', TPACPI_FAN_2CTL),  /* T15g (2nd gen) */
 	TPACPI_Q_LNV3('R', '1', 'F', TPACPI_FAN_NS),	/* L13 Yoga Gen 2 */
 	TPACPI_Q_LNV3('N', '2', 'U', TPACPI_FAN_NS),	/* X13 Yoga Gen 2*/
+	TPACPI_Q_LNV3('R', '0', 'R', TPACPI_FAN_NS),	/* L380 */
+	TPACPI_Q_LNV3('R', '1', '5', TPACPI_FAN_NS),	/* L13 Yoga Gen 1 */
+	TPACPI_Q_LNV3('R', '1', '0', TPACPI_FAN_NS),	/* L390 */
+	TPACPI_Q_LNV3('N', '2', 'L', TPACPI_FAN_NS),	/* X13 Yoga Gen 1 */
+	TPACPI_Q_LNV3('R', '0', 'T', TPACPI_FAN_NS),	/* 11e Gen5 GL */
+	TPACPI_Q_LNV3('R', '1', 'D', TPACPI_FAN_NS),	/* 11e Gen5 GL-R */
+	TPACPI_Q_LNV3('R', '0', 'V', TPACPI_FAN_NS),	/* 11e Gen5 KL-Y */
 	TPACPI_Q_LNV3('N', '1', 'O', TPACPI_FAN_NOFAN),	/* X1 Tablet (2nd gen) */
 };
 
Signature · 1 line
2.34.1
Reviewed-by on v1 1/1
#1 lore raw

Hi,

Quoted 6 lines · Vishnu Sankar

Add more ThinkPads with non-standard register addresses to read fan values.

ThinkPads added are L13 Yoga Gen1, X13 Yoga Gen1, L380, L390, 11e Gen5 GL, 11e Gen5 GL-R, 11e Gen5 KL-Y.

Thanks, I have no objection against this patch:

But this feels like it will become a game of whack-a-mole.

Mark can you reach out to the ThinkPad firmware team and figure out if there is some supported way to automatically detect this ?

Regards,

Hans

Quoted 22 lines
---
 drivers/platform/x86/thinkpad_acpi.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/platform/x86/thinkpad_acpi.c +7 -0
index 5ecd9d33250d..23b2abe44a5a 100644
@@ -8767,6 +8767,13 @@ static const struct tpacpi_quirk fan_quirk_table[] __initconst = {
 	TPACPI_Q_LNV3('N', '3', '7', TPACPI_FAN_2CTL),  /* T15g (2nd gen) */
 	TPACPI_Q_LNV3('R', '1', 'F', TPACPI_FAN_NS),	/* L13 Yoga Gen 2 */
 	TPACPI_Q_LNV3('N', '2', 'U', TPACPI_FAN_NS),	/* X13 Yoga Gen 2*/
+	TPACPI_Q_LNV3('R', '0', 'R', TPACPI_FAN_NS),	/* L380 */
+	TPACPI_Q_LNV3('R', '1', '5', TPACPI_FAN_NS),	/* L13 Yoga Gen 1 */
+	TPACPI_Q_LNV3('R', '1', '0', TPACPI_FAN_NS),	/* L390 */
+	TPACPI_Q_LNV3('N', '2', 'L', TPACPI_FAN_NS),	/* X13 Yoga Gen 1 */
+	TPACPI_Q_LNV3('R', '0', 'T', TPACPI_FAN_NS),	/* 11e Gen5 GL */
+	TPACPI_Q_LNV3('R', '1', 'D', TPACPI_FAN_NS),	/* 11e Gen5 GL-R */
+	TPACPI_Q_LNV3('R', '0', 'V', TPACPI_FAN_NS),	/* 11e Gen5 KL-Y */
 	TPACPI_Q_LNV3('N', '1', 'O', TPACPI_FAN_NOFAN),	/* X1 Tablet (2nd gen) */
 };
 
Reviewed-by
#2 lore raw

Hi Hans,

Quoted 12 lines · Hans de Goede

Hi,

Quoted 6 lines · Vishnu Sankar

Add more ThinkPads with non-standard register addresses to read fan values.

ThinkPads added are L13 Yoga Gen1, X13 Yoga Gen1, L380, L390, 11e Gen5 GL, 11e Gen5 GL-R, 11e Gen5 KL-Y.

Thanks, I have no objection against this patch:

Quoted 8 lines

But this feels like it will become a game of whack-a-mole.

Mark can you reach out to the ThinkPad firmware team and figure out if there is some supported way to automatically detect this ?

These are all older platforms and we're not expecting to see this on any newer platforms...if it shows up it's because they messed up (there is a spec and they're supposed to follow it). Vishnu did review with the FW team which platforms had used this implementation, and we believe the list below to be complete.

Vishnu, please correct me if you've heard otherwise.

As a note, I did review this during an internal review, before Vishnu pushed it, so I'll add:

Mark

#3 lore raw

Hi Hans and Mark,

Thanks for the review.

Quoted 20 lines · Mark Pearson

Hi Hans,

Quoted 16 lines · Hans de Goede

Hi,

Quoted 6 lines · Vishnu Sankar

Add more ThinkPads with non-standard register addresses to read fan values.

ThinkPads added are L13 Yoga Gen1, X13 Yoga Gen1, L380, L390, 11e Gen5 GL, 11e Gen5 GL-R, 11e Gen5 KL-Y.

Thanks, I have no objection against this patch:

But this feels like it will become a game of whack-a-mole.

Quoted 8 lines
Quoted 4 lines

Mark can you reach out to the ThinkPad firmware team and figure out if there is some supported way to automatically detect this ?

These are all older platforms and we're not expecting to see this on any newer platforms...if it shows up it's because they messed up (there is a spec and they're supposed to follow it). Vishnu did review with the FW team which platforms had used this implementation, and we believe the list below to be complete.

Vishnu, please correct me if you've heard otherwise.

This is confirmed by the FW team.
The list of systems is complete and no more systems are expected (as of now).

Quoted 6 lines

As a note, I did review this during an internal review, before Vishnu pushed it, so I'll add:

Mark

Signature · 4 lines
Regards,

      Vishnu Sankar
     +817015150407 (Japan)
maintainer
#4 lore raw
In reply to Vishnu Sankar
Quoted 6 lines · Vishnu Sankar

Add more ThinkPads with non-standard register addresses to read fan values.

ThinkPads added are L13 Yoga Gen1, X13 Yoga Gen1, L380, L390, 11e Gen5 GL, 11e Gen5 GL-R, 11e Gen5 KL-Y.

Thank you for your contribution, it has been applied to my local review-ilpo branch. Note it will show up in the public platform-drivers-x86/review-ilpo branch only once I've pushed my local branch there, which might take a while.

The list of commits applied:
[1/1] platform/x86: thinkpad_acpi: Add more ThinkPads with non-standard reg address for fan

      commit: 0dfb4617af0d4cfbaf75590a83e2ce367b67134a

--
i.