Index: scsi-misc-2.6/drivers/base/bus.c =================================================================== --- scsi-misc-2.6.orig/drivers/base/bus.c 2006-03-04 13:07:40.000000000 +0100 +++ scsi-misc-2.6/drivers/base/bus.c 2006-03-07 21:06:59.000000000 +0100 @@ -536,6 +536,28 @@ bus_for_each_dev(bus, NULL, NULL, bus_rescan_devices_helper); } +/** + * device_reprobe - remove driver for a device and probe for a new driver + * @dev: the device to reprobe + * + * This function detaches the attached driver (if any) for the given + * device and restarts the driver probing process. It is intended + * to use if probing criteria changed during a devices lifetime and + * driver attachment should change accordingly. + */ +void device_reprobe(struct device *dev) +{ + if (dev->driver) { + if (dev->parent) /* Needed for USB */ + down(&dev->parent->sem); + device_release_driver(dev); + if (dev->parent) + up(&dev->parent->sem); + } + + bus_rescan_devices_helper(dev, NULL); +} +EXPORT_SYMBOL_GPL(device_reprobe); struct bus_type * get_bus(struct bus_type * bus) { Index: scsi-misc-2.6/include/linux/device.h =================================================================== --- scsi-misc-2.6.orig/include/linux/device.h 2006-03-04 13:07:49.000000000 +0100 +++ scsi-misc-2.6/include/linux/device.h 2006-03-07 20:53:43.000000000 +0100 @@ -378,6 +378,7 @@ extern void device_release_driver(struct device * dev); extern int device_attach(struct device * dev); extern void driver_attach(struct device_driver * drv); +extern void device_reprobe(struct device *dev); /*