Skip to contentSkip to conversation

ACPI: EC: add quirk for Lenovo X13 G4 (AMD)

PATCH In review David Bauer 2 participants 5 messages Aug 31, 2024 – Sep 22, 2025 ACPI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ACPI: EC: add quirk for Lenovo X13 G4 (AMD)

This adds a quirk for the Lenovo X13 Gen 4 AMD platform.

If booted without the kernel-parameter acpi.ec_no_wakeup=1 the system will resume from sleep upon change of AC state. Unplugging or plugging the power cable thus wakes the system from suspend.

Disabling wakeups from the embedded controller fixes this behavior. Resuming by opening the lid stays functional.

Only apply this fix for the AMD version, as it is unknown if the Intel platform is also affected.

This was observed on a system with the following BIOS / EC software:
BIOS: 1.28 (R29ET54W)
EC: 1.31 (R29HT55W)

---
 drivers/acpi/ec.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/acpi/ec.c +7 -0
index 38d2f6e6b12b..f00cdcf06eb8 100644
@@ -2252,6 +2252,13 @@ static const struct dmi_system_id acpi_ec_no_wakeup[] = {
 			DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X1 Yoga 3rd"),
 		},
 	},
+	{
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			/* ThinkPad X13 Gen 4 (AMD) */
+			DMI_MATCH(DMI_PRODUCT_SKU, "LENOVO_MT_21J3_BU_Think_FM_ThinkPad X13 Gen 4"),
+		},
+	},
 	{
 		.matches = {
 			DMI_MATCH(DMI_SYS_VENDOR, "HP"),
Signature · 1 line
2.45.2
#1 lore raw

Hi David,

Quoted 41 lines · David Bauer

This adds a quirk for the Lenovo X13 Gen 4 AMD platform.

If booted without the kernel-parameter acpi.ec_no_wakeup=1 the system will resume from sleep upon change of AC state. Unplugging or plugging the power cable thus wakes the system from suspend.

Disabling wakeups from the embedded controller fixes this behavior. Resuming by opening the lid stays functional.

Only apply this fix for the AMD version, as it is unknown if the Intel platform is also affected.

This was observed on a system with the following BIOS / EC software:
BIOS: 1.28 (R29ET54W)
EC: 1.31 (R29HT55W)

---
 drivers/acpi/ec.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/acpi/ec.c +7 -0
index 38d2f6e6b12b..f00cdcf06eb8 100644
@@ -2252,6 +2252,13 @@ static const struct dmi_system_id acpi_ec_no_wakeup[] = {
 			DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X1 Yoga 3rd"),
 		},
 	},
+	{
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			/* ThinkPad X13 Gen 4 (AMD) */
+			DMI_MATCH(DMI_PRODUCT_SKU, "LENOVO_MT_21J3_BU_Think_FM_ThinkPad X13 Gen 4"),
+		},
+	},
 	{
 		.matches = {
 			DMI_MATCH(DMI_SYS_VENDOR, "HP"),
Signature · 1 line
2.45.2

I believe you've hit the issue that is being tracked in https://bugzilla.kernel.org/show_bug.cgi?id=219196

We're working with Qualcomm to get that addressed. It impacts systems with the Qualcomm Wifi chip that uses the ath11k driver. I haven't specifically reproduced it on the X13 G4 - but we've seen it on three other platforms and it sounds exactly the same.

You can confirm by using a 6.9 kernel and it should work correctly. If it doesn't, please let me know and we can investigate further. This is a Linux certified platform and I'd rather get issues fixed correctly than have to quirk them in the kernel and potentially impact other functionality.

Thanks
Mark

#2 lore raw

Hey Mark,

thanks for your message.

Quoted 47 lines · Mark Pearson

Hi David,

Quoted 41 lines · David Bauer

This adds a quirk for the Lenovo X13 Gen 4 AMD platform.

If booted without the kernel-parameter acpi.ec_no_wakeup=1 the system will resume from sleep upon change of AC state. Unplugging or plugging the power cable thus wakes the system from suspend.

Disabling wakeups from the embedded controller fixes this behavior. Resuming by opening the lid stays functional.

Only apply this fix for the AMD version, as it is unknown if the Intel platform is also affected.

This was observed on a system with the following BIOS / EC software:
BIOS: 1.28 (R29ET54W)
EC: 1.31 (R29HT55W)

---
  drivers/acpi/ec.c | 7 +++++++
  1 file changed, 7 insertions(+)
drivers/acpi/ec.c +7 -0
index 38d2f6e6b12b..f00cdcf06eb8 100644
@@ -2252,6 +2252,13 @@ static const struct dmi_system_id acpi_ec_no_wakeup[] = {
  			DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X1 Yoga 3rd"),
  		},
  	},
+	{
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			/* ThinkPad X13 Gen 4 (AMD) */
+			DMI_MATCH(DMI_PRODUCT_SKU, "LENOVO_MT_21J3_BU_Think_FM_ThinkPad X13 Gen 4"),
+		},
+	},
  	{
  		.matches = {
  			DMI_MATCH(DMI_SYS_VENDOR, "HP"),
Signature · 1 line
2.45.2

I believe you've hit the issue that is being tracked in https://bugzilla.kernel.org/show_bug.cgi?id=219196

Quoted 4 lines

We're working with Qualcomm to get that addressed. It impacts systems with the Qualcomm Wifi chip that uses the ath11k driver. I haven't specifically reproduced it on the X13 G4 - but we've seen it on three other platforms and it sounds exactly the same.

You can confirm by using a 6.9 kernel and it should work correctly. If it doesn't, please let me know and we can investigate further. This is a Linux certified platform and I'd rather get issues fixed correctly than have to quirk them in the kernel and potentially impact other functionality.

Understandable and i fully agree. I can confirm the wakeups do not occur on an older 6.9 kernel. So it's most likely the issue documented in the ticket.

I can also confirm that the wakes also happen when i disable Bluetooth and WiFi from within the BIOS and then boot Linux regardless of the kernel version.

Best
David

Quoted 3 lines

Thanks
Mark

#3 lore raw
In reply to Mark Pearson

Hey Mark,

Quoted 3 lines · Mark Pearson

I believe you've hit the issue that is being tracked in https://bugzilla.kernel.org/show_bug.cgi?id=219196

We're working with Qualcomm to get that addressed. It impacts systems with the Qualcomm Wifi chip that uses the ath11k driver. I haven't specifically reproduced it on the X13 G4 - but we've seen it on three other platforms and it sounds exactly the same.

I have seen patches [1] have been applied and gave 6.17 a spin.

First of all, the product number for my X13 G4 (21J3) was missing. I've added it myself to the list of platforms requiring the PM quirk, however I'm still seeing wakeups on AC power state changed while sleeping.

Does the patch retain sleep functionality on other platforms?
I'd love to help getting this fix, in the meantime i resort to acpi.ec_no_wakeup=1 which fixes these wakeups.

[1] https://github.com/torvalds/linux/commit/ce8669a27016354dfa8bf3c954255cb9f3583bae

Best
David

Quoted 6 lines

You can confirm by using a 6.9 kernel and it should work correctly. If it doesn't, please let me know and we can investigate further. This is a Linux certified platform and I'd rather get issues fixed correctly than have to quirk them in the kernel and potentially impact other functionality.

Thanks
Mark

#4 lore raw

Hi David,

Interesting - I thought we'd caught the impacted platforms, but it's possible that generation was missing.

I had an internal ticket open for suspend issue on that platform (LO-3142) and that notes that you need to update to BIOS 55W. Can you confirm which BIOS you're on just to rule out hitting that issue

Mark

Quoted 32 lines · David Bauer

Hey Mark,

Quoted 3 lines · Mark Pearson

I believe you've hit the issue that is being tracked in https://bugzilla.kernel.org/show_bug.cgi?id=219196

We're working with Qualcomm to get that addressed. It impacts systems with the Qualcomm Wifi chip that uses the ath11k driver. I haven't specifically reproduced it on the X13 G4 - but we've seen it on three other platforms and it sounds exactly the same.

I have seen patches [1] have been applied and gave 6.17 a spin.

First of all, the product number for my X13 G4 (21J3) was missing. I've added it myself to
the list of platforms requiring the PM quirk, however I'm still seeing wakeups on AC power
state changed while sleeping.

Does the patch retain sleep functionality on other platforms? I'd love to help getting this fix, in the meantime i resort to acpi.ec_no_wakeup=1
which fixes these wakeups.

[1]
https://github.com/torvalds/linux/commit/ce8669a27016354dfa8bf3c954255cb9f3583bae

Best
David

Quoted 6 lines

You can confirm by using a 6.9 kernel and it should work correctly. If it doesn't, please let me know and we can investigate further. This is a Linux certified platform and I'd rather get issues fixed correctly than have to quirk them in the kernel and potentially impact other functionality.

Thanks
Mark