aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authormochel@digitalimplant.org <mochel@digitalimplant.org>2005-03-21 15:25:36 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-20 18:15:16 -0400
commit94e7b1c5ff2055571703e38b059afffe17658432 (patch)
tree469dbd920087ec62acd88b4985437a78c6786c0e /include
parent38fdac3cdce276554b4484a41f8ec2daf81cb2ff (diff)
[PATCH] Add a klist to struct device_driver for the devices bound to it.
- Use it in driver_for_each_device() instead of the regular list_head and stop using the bus's rwsem for protection. - Use driver_for_each_device() in driver_detach() so we don't deadlock on the bus's rwsem. - Remove ->devices. - Move klist access and sysfs link access out from under device's semaphore, since they're synchronized through other means. Signed-off-by: Patrick Mochel <mochel@digitalimplant.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include')
-rw-r--r--include/linux/device.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index ea9ab33dfe71..96c71b59fdef 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -105,7 +105,7 @@ struct device_driver {
105 105
106 struct completion unloaded; 106 struct completion unloaded;
107 struct kobject kobj; 107 struct kobject kobj;
108 struct list_head devices; 108 struct klist klist_devices;
109 struct klist_node knode_bus; 109 struct klist_node knode_bus;
110 110
111 struct module * owner; 111 struct module * owner;
@@ -266,6 +266,7 @@ struct device {
266 struct list_head bus_list; /* node in bus's list */ 266 struct list_head bus_list; /* node in bus's list */
267 struct list_head driver_list; 267 struct list_head driver_list;
268 struct list_head children; 268 struct list_head children;
269 struct klist_node knode_driver;
269 struct klist_node knode_bus; 270 struct klist_node knode_bus;
270 struct device * parent; 271 struct device * parent;
271 272