summaryrefslogtreecommitdiff
path: root/drivers/usb/wusbcore/wa-hc.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/wusbcore/wa-hc.c')
-rw-r--r--drivers/usb/wusbcore/wa-hc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/wusbcore/wa-hc.c b/drivers/usb/wusbcore/wa-hc.c
index 252c7bd9218a..d01496fd27fe 100644
--- a/drivers/usb/wusbcore/wa-hc.c
+++ b/drivers/usb/wusbcore/wa-hc.c
@@ -39,6 +39,9 @@ int wa_create(struct wahc *wa, struct usb_interface *iface,
int result;
struct device *dev = &iface->dev;
+ if (iface->cur_altsetting->desc.bNumEndpoints < 3)
+ return -ENODEV;
+
result = wa_rpipes_create(wa);
if (result < 0)
goto error_rpipes_create;