Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 79a8f70b authored by Kristen Carlson Accardi's avatar Kristen Carlson Accardi Committed by Len Brown
Browse files

ACPI: dock: send envp with uevent



Send an env along with our KOBJ_CHANGE uevent so that user space has
the option of checking for that to see if a dock or undock has occurred.

Signed-off-by: default avatarKristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent 9ef2a9a9
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -336,11 +336,19 @@ static void hotplug_dock_devices(struct dock_station *ds, u32 event)
static void dock_event(struct dock_station *ds, u32 event, int num)
{
	struct device *dev = &dock_device->dev;
	char event_string[7];
	char *envp[] = { event_string, NULL };

	if (num == UNDOCK_EVENT)
		sprintf(event_string, "UNDOCK");
	else
		sprintf(event_string, "DOCK");

	/*
	 * Indicate that the status of the dock station has
	 * changed.
	 */
	kobject_uevent(&dev->kobj, KOBJ_CHANGE);
	kobject_uevent_env(&dev->kobj, KOBJ_CHANGE, envp);
}

/**