1
0
Fork 0

staging: ozwpan: Check for correct config number.

Check for valid config number before completing set interface.

Signed-off-by: Rupesh Gujare <rupesh.gujare@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
hifive-unleashed-5.1
Rupesh Gujare 2013-08-23 18:33:28 +01:00 committed by Greg Kroah-Hartman
parent 9d5829bfba
commit 050596a488
1 changed files with 1 additions and 1 deletions

View File

@ -909,7 +909,7 @@ static void oz_hcd_complete_set_interface(struct oz_port *port, struct urb *urb,
struct usb_hcd *hcd = port->ozhcd->hcd;
int rc = 0;
if (rcode == 0) {
if ((rcode == 0) && (port->config_num > 0)) {
struct usb_host_config *config;
struct usb_host_interface *intf;
oz_dbg(ON, "Set interface %d alt %d\n", if_num, alt);