If a device can't be configured, the current test9 code forgets to clean it out of sysfs. This resolves that issue, so the retry in usb_new_device() stands a chance of working.
The enumeration code still doesn't handle such errors well, but at least this way that hub port can be used for another device.
- Dave
--- 1.144/drivers/usb/core/usb.c Thu Oct 23 15:07:00 2003
+++ edited/drivers/usb/core/usb.c Fri Nov 14 08:18:31 2003
@@ -1120,6 +1120,7 @@
if (err) {
dev_err(&dev->dev, "can't set config #%d, error %d\n",
dev->config[0].desc.bConfigurationValue, err);
+ device_del (&dev->dev);
goto fail;
}
