aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core/devio.c
diff options
context:
space:
mode:
authorDavid Vrabel <[email protected]>2009-02-18 14:43:47 +0000
committerGreg Kroah-Hartman <[email protected]>2009-03-24 23:20:35 +0000
commit6da9c99059bf24fb1faae6b9613bae64ea50c05e (patch)
treef190e2d2b6daab5d8b02c57b24ac37f43a50c1b7 /drivers/usb/core/devio.c
parentUSB: usb-storage: added missing MODULE_LICENSE("GPL") for usb-storage ums-* m... (diff)
downloadkernel-6da9c99059bf24fb1faae6b9613bae64ea50c05e.tar.gz
kernel-6da9c99059bf24fb1faae6b9613bae64ea50c05e.zip
USB: allow libusb to talk to unauthenticated WUSB devices
To permit a userspace application to associate with WUSB devices using numeric association, control transfers to unauthenticated WUSB devices must be allowed. This requires that wusbcore correctly sets the device state to UNAUTHENTICATED, DEFAULT and ADDRESS and that control transfers can be performed to UNAUTHENTICATED devices. Signed-off-by: David Vrabel <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'drivers/usb/core/devio.c')
-rw-r--r--drivers/usb/core/devio.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/core/devio.c b/drivers/usb/core/devio.c
index 6585f527e381..8f022af2fd7a 100644
--- a/drivers/usb/core/devio.c
+++ b/drivers/usb/core/devio.c
@@ -525,7 +525,8 @@ static int check_ctrlrecip(struct dev_state *ps, unsigned int requesttype,
{
int ret = 0;
- if (ps->dev->state != USB_STATE_ADDRESS
+ if (ps->dev->state != USB_STATE_UNAUTHENTICATED
+ && ps->dev->state != USB_STATE_ADDRESS
&& ps->dev->state != USB_STATE_CONFIGURED)
return -EHOSTUNREACH;
if (USB_TYPE_VENDOR == (USB_TYPE_MASK & requesttype))