Commit 050596a4 authored by Rupesh Gujare's avatar Rupesh Gujare Committed by Greg Kroah-Hartman

staging: ozwpan: Check for correct config number.

Check for valid config number before completing set interface.
Signed-off-by: default avatarRupesh Gujare <rupesh.gujare@atmel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9d5829bf
......@@ -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);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment