Skip to contentSkip to conversation

platform/x86: ideapad-laptop: send notification about touchpad state change to sysfs

PATCH Superseded Barnabás Pőcze 1 participant 1 message Dec 16, 2020 x86 platform drivers

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 20/24 platform/x86: ideapad-laptop: send notification about touchpad state change to sysfs

Consumers can determine if the value of an attribute changed much more easily if changes are broadcast using sysfs_notify(), so utilize it.

drivers/platform/x86/ideapad-laptop.c +1 -0
index 491cadbf15ec..075056075b2d 100644
@@ -953,6 +953,7 @@ static void ideapad_sync_touchpad_state(struct ideapad_private *priv)
 		i8042_command(&param,
 			      value ? I8042_CMD_AUX_ENABLE : I8042_CMD_AUX_DISABLE);
 		ideapad_input_report(priv, value ? 67 : 66);
+		sysfs_notify(&priv->platform_device->dev.kobj, NULL, "touchpad");
 	}
 }
 
Signature · 1 line
2.29.2