diff options
author | Cornelia Huck <cornelia.huck@de.ibm.com> | 2007-02-05 16:15:26 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-04-27 10:57:29 -0700 |
commit | c6a46696f97ff260a4ecce5e287f8de4b9d7fe14 (patch) | |
tree | 335de50c9868cd575f535677e430677d33cbaaa1 /drivers/base/base.h | |
parent | eed40d3ad2ba652c08422d62a5ff6f62ac0be16d (diff) | |
download | op-kernel-dev-c6a46696f97ff260a4ecce5e287f8de4b9d7fe14.zip op-kernel-dev-c6a46696f97ff260a4ecce5e287f8de4b9d7fe14.tar.gz |
driver core: don't fail attaching the device if it cannot be bound
Don't fail bus_attach_device() if the device cannot be bound.
If dev->driver has been specified, reset it to NULL if device_bind_driver()
failed and add the device as an unbound device. As a result,
bus_attach_device() now cannot fail, and we can remove some checking from
device_add().
Also remove an unneeded check in bus_rescan_devices_helper().
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/base/base.h')
-rw-r--r-- | drivers/base/base.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/base.h b/drivers/base/base.h index de7e144..d597f26 100644 --- a/drivers/base/base.h +++ b/drivers/base/base.h @@ -16,7 +16,7 @@ extern int cpu_dev_init(void); extern int attribute_container_init(void); extern int bus_add_device(struct device * dev); -extern int bus_attach_device(struct device * dev); +extern void bus_attach_device(struct device * dev); extern void bus_remove_device(struct device * dev); extern struct bus_type *get_bus(struct bus_type * bus); extern void put_bus(struct bus_type * bus); |