usb: dwc3: ep0: add a default case for SetFeature command
authorGerard Cauvy <g-cauvy1@ti.com>
Fri, 16 Mar 2012 14:20:10 +0000 (16:20 +0200)
committerFelipe Balbi <balbi@ti.com>
Tue, 10 Apr 2012 16:11:31 +0000 (19:11 +0300)
Without this default case returning an error,
thus replying with a stall, we would fail
USB30CV TD 9.11 Bad Feature test case.

Cc: stable@vger.kernel.org
Signed-off-by: Gerard Cauvy <g-cauvy1@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc3/ep0.c

index da43131..3584a16 100644 (file)
@@ -353,6 +353,9 @@ static int dwc3_ep0_handle_feature(struct dwc3 *dwc,
 
                        dwc->test_mode_nr = wIndex >> 8;
                        dwc->test_mode = true;
+                       break;
+               default:
+                       return -EINVAL;
                }
                break;