Greg:

This patch adds some simple cleanups that are missing for one of the error
case in usb_register_root_hub().  I would be very surprised if this code
ever gets executed, but we might as well be correct.

Please apply.

Alan Stern



Signed-off-by: Alan Stern <[EMAIL PROTECTED]>

===== drivers/usb/core/hcd.c 1.147 vs edited =====
--- 1.147/drivers/usb/core/hcd.c        Thu Jun 24 12:44:16 2004
+++ edited/drivers/usb/core/hcd.c       Mon Jul 12 15:55:12 2004
@@ -790,6 +790,8 @@
        usb_dev->epmaxpacketin[0] = usb_dev->epmaxpacketout[0] = 64;
        retval = usb_get_device_descriptor(usb_dev, USB_DT_DEVICE_SIZE);
        if (retval != sizeof usb_dev->descriptor) {
+               usb_dev->bus->root_hub = NULL;
+               up (&usb_bus_list_lock);
                dev_dbg (parent_dev, "can't read %s device descriptor %d\n",
                                usb_dev->dev.bus_id, retval);
                return (retval < 0) ? retval : -EMSGSIZE;



-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to