Skip to contentSkip to conversation

intel-hid: fix volume buttons on Thinkpad X12 Detachable Tablet Gen 1

PATCH In review Cole Stowell 3 participants 3 messages Nov 7, 2024 – Nov 12, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 intel-hid: fix volume buttons on Thinkpad X12 Detachable Tablet Gen 1

Volume buttons on Lenovo Thinkpad X12 Detachable Tablet Gen 1 did not send any input events when pressed. When loading intel-hid with the 5 Button Array explicitly enabled, the buttons functioned normally.

Adds the X12 Detachable Tablet Gen 1 to the button_array_table.

However, the driver is unable to call INTEL_HID_DSM_BTNE_FN and prints the warning "failed to set button capability" when attempting to enable or disable the 5 Button Array. I'm not sure if this is normal, but the warning seems harmless.

---
 drivers/platform/x86/intel/hid.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/platform/x86/intel/hid.c +0 -0
index 445e7a59beb4..48ad75a56199 100644
@@ -118,6 +118,13 @@ static const s

truct dmi_system_id button_array_table[] = {
DMI_MATCH(DMI_PRODUCT_NAME, "HP Spectre x2 Detachable"),
},
},
+ {
+ .ident = "Lenovo ThinkPad X1 Tablet Gen 1",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+ DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X12 Detachable Gen 1"),
+ },
+ },
{
.ident = "Lenovo ThinkPad X1 Tablet Gen 2", .matches = {

Signature · 1 line
2.47.0
Reviewed-by on v1 1/1
#1 lore raw

Hi,

Thank you for the patch.

Quoted 10 lines · Cole Stowell

Volume buttons on Lenovo Thinkpad X12 Detachable Tablet Gen 1 did not send any input events when pressed. When loading intel-hid with the 5 Button Array explicitly enabled, the buttons functioned normally.

Adds the X12 Detachable Tablet Gen 1 to the button_array_table.

However, the driver is unable to call INTEL_HID_DSM_BTNE_FN and prints the warning "failed to set button capability" when attempting to enable or disable the 5 Button Array. I'm not sure if this is normal, but the warning seems harmless.

Yes the warning should be harmless and adding more special handling is not worth it IMHO.

Patch looks good to me:

Regards,

Hans

Quoted 26 lines
---
 drivers/platform/x86/intel/hid.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/platform/x86/intel/hid.c +7 -0
index 445e7a59beb4..48ad75a56199 100644
@@ -118,6 +118,13 @@ static const s
 truct dmi_system_id button_array_table[] = {
 			DMI_MATCH(DMI_PRODUCT_NAME, "HP Spectre x2 Detachable"),
 		},
 	},
+	{
+		.ident = "Lenovo ThinkPad X1 Tablet Gen 1",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X12 Detachable Gen 1"),
+		},
+	},
 	{
 		.ident = "Lenovo ThinkPad X1 Tablet Gen 2",

.matches = {

maintainer
#2 lore raw
Quoted 16 lines · Hans de Goede

Hi,

Thank you for the patch.

Quoted 10 lines · Cole Stowell

Volume buttons on Lenovo Thinkpad X12 Detachable Tablet Gen 1 did not send any input events when pressed. When loading intel-hid with the 5 Button Array explicitly enabled, the buttons functioned normally.

Adds the X12 Detachable Tablet Gen 1 to the button_array_table.

However, the driver is unable to call INTEL_HID_DSM_BTNE_FN and prints the warning "failed to set button capability" when attempting to enable or disable the 5 Button Array. I'm not sure if this is normal, but the warning seems harmless.

Quoted 6 lines

Yes the warning should be harmless and adding more special handling is not worth it IMHO.

Patch looks good to me:

Hi,

I've applied this into review-ilpo branch but edited the commit message slightly by using the text from Hans' reply.

Signature · 1 line
 i.
Quoted 27 lines
Quoted 26 lines
---
 drivers/platform/x86/intel/hid.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/platform/x86/intel/hid.c +7 -0
index 445e7a59beb4..48ad75a56199 100644
@@ -118,6 +118,13 @@ static const s
 truct dmi_system_id button_array_table[] = {
 			DMI_MATCH(DMI_PRODUCT_NAME, "HP Spectre x2 Detachable"),
 		},
 	},
+	{
+		.ident = "Lenovo ThinkPad X1 Tablet Gen 1",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			DMI_MATCH(DMI_PRODUCT_FAMILY, "ThinkPad X12 Detachable Gen 1"),
+		},
+	},
 	{
 		.ident = "Lenovo ThinkPad X1 Tablet Gen 2",

.matches = {