]> nv-tegra.nvidia Code Review - linux-3.10.git/commitdiff
ACPI: dock: add uevent to indicate change in device status
authorKristen Carlson Accardi <kristen.c.accardi@intel.com>
Mon, 11 Dec 2006 20:05:08 +0000 (12:05 -0800)
committerLen Brown <len.brown@intel.com>
Thu, 14 Dec 2006 22:16:06 +0000 (17:16 -0500)
Send a uevent to indicate a device change whenever we dock or
undock, so that userspace may now check the dock status via sysfs.

Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Holger Macht <hmacht@suse.de>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/dock.c

index 8c6828bee5d97fbd536e9fa90e3022f94192da3b..215f5b30a1f1993f5fa2dab51be452d6e90b3e92 100644 (file)
@@ -326,10 +326,12 @@ 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;
        /*
-        * we don't do events until someone tells me that
-        * they would like to have them.
+        * Indicate that the status of the dock station has
+        * changed.
         */
+       kobject_uevent(&dev->kobj, KOBJ_CHANGE);
 }
 
 /**