On Wednesday 23 May 2007, Alan Stern wrote: > On Wed, 23 May 2007, Pandita, Vikram wrote: > > > New proposed patch based on your inputs: > > > > Patch is to prevent the OTG host of doing 3 times enumeration of device > > when the Host suspends for HNP. The error code used in this case is > > ENOTSUPP. > > > > Signed-off-by: Vikram Pandita <[EMAIL PROTECTED]> > > --- > > diff -purN -X ./dontdiff a/drivers/usb/core/hub.c c/drivers/usb/core/hub.c > > --- a/drivers/usb/core/hub.c 2007-05-13 14:24:43.000000000 +0530 > > +++ c/drivers/usb/core/hub.c 2007-05-23 11:58:40.000000000 +0530 > > @@ -1361,7 +1361,7 @@ int usb_new_device(struct usb_device *ud > > if (err < 0) > > dev_dbg(&udev->dev, "HNP fail, %d\n", err); > > } > > - err = -ENODEV; > > + err = -ENOTSUPP; > > goto fail; > > } > > #endif > > @@ -2571,7 +2571,7 @@ loop: > > ep0_reinit(udev); > > release_address(udev); > > usb_put_dev(udev); > > - if (status == -ENOTCONN) > > + if ((status == -ENOTCONN) || (status == -ENOTSUPP)) > > break; > > } > > This looks good. > > Acked-by: Alan Stern <[EMAIL PROTECTED]>
Ditto. Greg, it'd be nice to see this in 2.6.22 if possible; there's a bunch of recent work on OTG hardware, and it'd be nice if folk doing that work only had to carry around driver patches, not usbcore patches. - Dave ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel