Skip to contentSkip to conversation

platform/x86: dell-wmi: Ignore suspend notifications

PATCH In review Armin Wolf 3 participants 4 messages Oct 14, 2024 – Oct 21, 2024

Subsystems (2)
lore
Share & tools
lore

Armin Wolf

author
#0 lore raw

PATCH 1/1 platform/x86: dell-wmi: Ignore suspend notifications

Some machines like the Dell G15 5155 emit WMI events when suspending/resuming. Ignore those WMI events.

---
For some reason [email protected] causes a local error in processing.

---
 drivers/platform/x86/dell/dell-wmi-base.c | 9 +++++++++
 1 file changed, 9 insertions(+)
drivers/platform/x86/dell/dell-wmi-base.c +9 -0
index 502783a7adb1..24fd7ffadda9 100644
@@ -264,6 +264,15 @@ static const struct key_entry dell_wmi_keymap_type_0010[] = {
 	/*Speaker Mute*/
 	{ KE_KEY, 0x109, { KEY_MUTE} },
 
+	/* S2Idle screen off */
+	{ KE_IGNORE, 0x120, { KEY_RESERVED }},
+
+	/* Leaving S4 or S2Idle suspend */
+	{ KE_IGNORE, 0x130, { KEY_RESERVED }},
+
+	/* Entering S2Idle suspend */
+	{ KE_IGNORE, 0x140, { KEY_RESERVED }},
+
 	/* Mic mute */
 	{ KE_KEY, 0x150, { KEY_MICMUTE } },
 

--
2.39.5

maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 5 lines · On Tuesday 15 October 2024 00:05:29 Armin Wolf wrote:

Some machines like the Dell G15 5155 emit WMI events when suspending/resuming. Ignore those WMI events.

Looks good,

Quoted 29 lines

---
For some reason [email protected] causes a local error in processing.

---
 drivers/platform/x86/dell/dell-wmi-base.c | 9 +++++++++
 1 file changed, 9 insertions(+)
drivers/platform/x86/dell/dell-wmi-base.c +9 -1
index 502783a7adb1..24fd7ffadda9 100644
@@ -264,6 +264,15 @@ static const struct key_entry dell_wmi_keymap_type_0010[] = {
 	/*Speaker Mute*/
 	{ KE_KEY, 0x109, { KEY_MUTE} },
 
+	/* S2Idle screen off */
+	{ KE_IGNORE, 0x120, { KEY_RESERVED }},
+
+	/* Leaving S4 or S2Idle suspend */
+	{ KE_IGNORE, 0x130, { KEY_RESERVED }},
+
+	/* Entering S2Idle suspend */
+	{ KE_IGNORE, 0x140, { KEY_RESERVED }},
+
 	/* Mic mute */
 	{ KE_KEY, 0x150, { KEY_MICMUTE } },
 
--

2.39.5

#2 lore raw
In reply to Armin Wolf

Hi,

Quoted 5 lines · Armin Wolf

Some machines like the Dell G15 5155 emit WMI events when suspending/resuming. Ignore those WMI events.

Thank you for your patch, I've applied this patch to my review-hans branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=review-hans

Note it will show up in my review-hans branch once I've pushed my local branch there, which might take a while.

I will include this patch in my next fixes pull-req to Linus for the current kernel development cycle.

Regards,

Hans

Quoted 29 lines

---
For some reason [email protected] causes a local error in processing.

---
 drivers/platform/x86/dell/dell-wmi-base.c | 9 +++++++++
 1 file changed, 9 insertions(+)
drivers/platform/x86/dell/dell-wmi-base.c +9 -1
index 502783a7adb1..24fd7ffadda9 100644
@@ -264,6 +264,15 @@ static const struct key_entry dell_wmi_keymap_type_0010[] = {
 	/*Speaker Mute*/
 	{ KE_KEY, 0x109, { KEY_MUTE} },
 
+	/* S2Idle screen off */
+	{ KE_IGNORE, 0x120, { KEY_RESERVED }},
+
+	/* Leaving S4 or S2Idle suspend */
+	{ KE_IGNORE, 0x130, { KEY_RESERVED }},
+
+	/* Entering S2Idle suspend */
+	{ KE_IGNORE, 0x140, { KEY_RESERVED }},
+
 	/* Mic mute */
 	{ KE_KEY, 0x150, { KEY_MICMUTE } },
 
--

2.39.5

author
#3 lore raw

Am 21.10.24 um 16:23 schrieb Hans de Goede:

Quoted 15 lines

Hi,

Quoted 5 lines · Armin Wolf

Some machines like the Dell G15 5155 emit WMI events when suspending/resuming. Ignore those WMI events.

Thank you for your patch, I've applied this patch to my review-hans branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=review-hans

Note it will show up in my review-hans branch once I've pushed my local branch there, which might take a while.

Quoted 6 lines

I will include this patch in my next fixes pull-req to Linus for the current kernel development cycle.

Regards,

Hans

Thanks :)

Quoted 30 lines
Quoted 29 lines

---
For some reason [email protected] causes a local error in processing.

---
  drivers/platform/x86/dell/dell-wmi-base.c | 9 +++++++++
  1 file changed, 9 insertions(+)
drivers/platform/x86/dell/dell-wmi-base.c +9 -1
index 502783a7adb1..24fd7ffadda9 100644
@@ -264,6 +264,15 @@ static const struct key_entry dell_wmi_keymap_type_0010[] = {
  	/*Speaker Mute*/
  	{ KE_KEY, 0x109, { KEY_MUTE} },
 
+	/* S2Idle screen off */
+	{ KE_IGNORE, 0x120, { KEY_RESERVED }},
+
+	/* Leaving S4 or S2Idle suspend */
+	{ KE_IGNORE, 0x130, { KEY_RESERVED }},
+
+	/* Entering S2Idle suspend */
+	{ KE_IGNORE, 0x140, { KEY_RESERVED }},
+
  	/* Mic mute */
  	{ KE_KEY, 0x150, { KEY_MICMUTE } },
 
--

2.39.5