From: David Brownell Date: Sun, 16 Nov 2008 03:53:21 +0000 (-0800) Subject: USB: gadget rndis: stop windows self-immolation X-Git-Tag: Release-2010-05/1~2^2~148 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=pandora-kernel.git;a=commitdiff_plain;h=86f4831829db0c5dcacadf23e53d41c9e3de6ff7 USB: gadget rndis: stop windows self-immolation Somewhere in the conversion of the RNDIS gadget code to the new framework, the descriptor of its data interface seems to have been copied from the CDC Ethernet driver. Unfortunately that means it got a nonzero altsetting ... which is incorrect. Issue uncovered by Richard Röjfors . This patch fixes that problem, and resolves at least some cases of Windows XP bluescreening itself. Tested-by: Richard Röjfors . Signed-off-by: David Brownell Cc: stable Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/gadget/f_rndis.c b/drivers/usb/gadget/f_rndis.c index 659b3d9671c4..8afb14a4a72f 100644 --- a/drivers/usb/gadget/f_rndis.c +++ b/drivers/usb/gadget/f_rndis.c @@ -172,7 +172,6 @@ static struct usb_interface_descriptor rndis_data_intf __initdata = { .bDescriptorType = USB_DT_INTERFACE, /* .bInterfaceNumber = DYNAMIC */ - .bAlternateSetting = 1, .bNumEndpoints = 2, .bInterfaceClass = USB_CLASS_CDC_DATA, .bInterfaceSubClass = 0,