Skip to contentSkip to conversation

AMD_SFH: Add a DMI quirk entry for Chromebooks

PATCH Superseded Akihiko Odaki 3 participants 6 messages Jul 14, 2022 – Aug 15, 2022

Subsystems (2)

v2 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 AMD_SFH: Add a DMI quirk entry for Chromebooks

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub instead of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

---
 drivers/hid/amd-sfh-hid/amd_sfh_pcie.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)
drivers/hid/amd-sfh-hid/amd_sfh_pcie.c +12 -0
index dadc491bbf6b..b91e1c95e543 100644
@@ -197,6 +197,18 @@ static const struct dmi_system_id dmi_sensor_mask_overrides[] = {
 		},
 		.driver_data = (void *)(ACEL_EN | MAGNO_EN),
 	},
+	{
+		/*
+		 * Google Chromebooks use Chrome OS Embedded Controller Sensor
+		 * Hub instead of Sensor Hub Fusion and leaves MP2
+		 * uninitialized, which disables all functionalities, even
+		 * including the registers necessary for feature detections.
+		 */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Google"),
+		},
+		.driver_data = (void *)0,
+	},
 	{ }
 };
 
Signature · 1 line
2.36.1
#1 lore raw
Quoted 26 lines · Akihiko Odaki

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub instead of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

---
  drivers/hid/amd-sfh-hid/amd_sfh_pcie.c | 12 ++++++++++++
  1 file changed, 12 insertions(+)
drivers/hid/amd-sfh-hid/amd_sfh_pcie.c +5 -0
index dadc491bbf6b..b91e1c95e543 100644
@@ -197,6 +197,18 @@ static const struct dmi_system_id dmi_sensor_mask_overrides[] = {
  		},
  		.driver_data = (void *)(ACEL_EN | MAGNO_EN),
  	},
+	{
+		/*
+		 * Google Chromebooks use Chrome OS Embedded Controller Sensor
+		 * Hub instead of Sensor Hub Fusion and leaves MP2
+		 * uninitialized, which disables all functionalities, even

drivers/hid/amd-sfh-hid/amd_sfh_pcie.c static const struct dmi_system_id dmi_sensor_mask_overrides[] = { · line 214

Quoted 10 lines
drivers/hid/amd-sfh-hid/amd_sfh_pcie.c +7 -0
+		 * including the registers necessary for feature detections.
+		 */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Google"),
+		},
+		.driver_data = (void *)0,
+	},
  	{ }
  };
 

Did you miss my other comment on v1 on discovery sensor probing or is it not a problem?

#2 lore raw
In reply to Akihiko Odaki
Quoted 6 lines · Akihiko Odaki

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub instead of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

We are checking for few things with respect to this issue internally.

Please hold on this patch. we will get back soon.

Thanks,
Basavaraj

#3 lore raw
In reply to Akihiko Odaki
Quoted 8 lines · Akihiko Odaki

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub instead of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

This driver should not get loaded in chrome OS by default.
Could you please provide details of Chrome OS Version and Kernel version to confirm the behavior.

Are you enabling manually CONFIG_AMD_SFH_HID config?

Thanks,
Basavaraj

#4 lore raw
Quoted 11 lines · Basavaraj Natikar
Quoted 8 lines · Akihiko Odaki

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub instead of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

Quoted 8 lines

This driver should not get loaded in chrome OS by default.
Could you please provide details of Chrome OS Version and Kernel version to confirm the behavior.

Are you enabling manually CONFIG_AMD_SFH_HID config?

Thanks,
Basavaraj

I use Fedora 36, not Chrome OS. The config is enabled on Fedora's generic kernel. The kernel is built from commit 78ca55889a549a9a194c6ec666836329b774ab6d from the upstream.

Regards,
Akihiko Odaki

#5 lore raw

[Public]

Quoted 33 lines

-----Original Message-----
From: Akihiko Odaki <[email protected]>
Sent: Thursday, July 14, 2022 23:46
To: Natikar, Basavaraj <[email protected]>
Cc: Natikar, Basavaraj <[email protected]>; Jiri Kosina <[email protected]>; Benjamin Tissoires <[email protected]>; [email protected]; [email protected]; Limonciello, Mario <[email protected]>
Subject: Re: [PATCH v2] AMD_SFH: Add a DMI quirk entry for Chromebooks

Quoted 4 lines · Basavaraj Natikar
Quoted 1 line · Akihiko Odaki

Google Chromebooks use Chrome OS Embedded Controller Sensor Hub

instead

Quoted 9 lines
Quoted 7 lines

of Sensor Hub Fusion and leaves MP2 uninitialized, which disables all functionalities, even including the registers necessary for feature detections.

The behavior was observed with Lenovo ThinkPad C13 Yoga.

This driver should not get loaded in chrome OS by default. Could you please provide details of Chrome OS Version and Kernel version

to confirm the behavior.

Quoted 6 lines

Are you enabling manually CONFIG_AMD_SFH_HID config?

Thanks,
Basavaraj

Quoted 6 lines

I use Fedora 36, not Chrome OS. The config is enabled on Fedora's generic kernel. The kernel is built from commit 78ca55889a549a9a194c6ec666836329b774ab6d from the upstream.

Regards,
Akihiko Odaki

Akihiko,

FWIW - I think your patch is the correct direction for your situation (trying to load Fedora onto a system that previously shipped with ChromeOS).

I think you just need to check the question that I had about discovery registers and if that probing is still a problem or not.

Thanks,