Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=ffcdc18d64d73ecce49c182f969977ae88ff4384
Commit:     ffcdc18d64d73ecce49c182f969977ae88ff4384
Parent:     b29dbbd811b006deea85275e37fc1a09e8983d48
Author:     Vikram Pandita <[EMAIL PROTECTED]>
AuthorDate: Fri May 25 21:31:07 2007 -0700
Committer:  Greg Kroah-Hartman <[EMAIL PROTECTED]>
CommitDate: Thu Jul 12 16:29:51 2007 -0700

    USB Core: hub.c: prevent re-enumeration on HNP
    
    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]>
    Acked-by: Alan Stern <[EMAIL PROTECTED]>
    Acked-by: David Brownell <[EMAIL PROTECTED]>
    Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>
---
 drivers/usb/core/hub.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 08f0c22..7946d7b 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -1443,7 +1443,7 @@ int usb_new_device(struct usb_device *udev)
                        if (err < 0)
                                dev_dbg(&udev->dev, "HNP fail, %d\n", err);
                }
-               err = -ENODEV;
+               err = -ENOTSUPP;
                goto fail;
        }
 #endif
@@ -2582,7 +2582,7 @@ loop:
                ep0_reinit(udev);
                release_address(udev);
                usb_put_dev(udev);
-               if (status == -ENOTCONN)
+               if ((status == -ENOTCONN) || (status == -ENOTSUPP))
                        break;
        }
  
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to