public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] USB config selection for RNDIS devices
@ 2007-03-27 21:30 Ingo van Lil
  0 siblings, 0 replies; only message in thread
From: Ingo van Lil @ 2007-03-27 21:30 UTC (permalink / raw)
  To: linux-kernel

Hi there,

the USB configuration selection code in drivers/usb/core/generic.c will
refuse to use an RNDIS-only device if the RNDIS driver is compiled as a
module. The straightforward solution would be to change the #ifndef test
to include CONFIG_USB_NET_RNDIS_HOST_MODULE as well, but I'd rather
suggest to drop the entire check instead. That way the RNDIS-case will
be treated just like a vendor-specific configuration: It will be chosen
only if no better choice (e.g. CDC) can be found.

Cheers,
Ingo

Signed-off-by: Ingo van Lil <inguin@gmx.de>
---
--- drivers/usb/core/generic.c.orig	2007-03-27 23:03:17.000000000 +0200
+++ drivers/usb/core/generic.c	2007-03-27 23:06:18.000000000 +0200
@@ -88,17 +88,13 @@
 		}

 		/* If the first config's first interface is COMM/2/0xff
-		 * (MSFT RNDIS), rule it out unless Linux has host-side
-		 * RNDIS support. */
+		 * (MSFT RNDIS), select it but keep scanning something
+		 * better (ideally a CDC ethernet interface). */
 		if (i == 0 && desc
 				&& desc->bInterfaceClass == USB_CLASS_COMM
 				&& desc->bInterfaceSubClass == 2
 				&& desc->bInterfaceProtocol == 0xff) {
-#ifndef CONFIG_USB_NET_RNDIS_HOST
-			continue;
-#else
 			best = c;
-#endif
 		}

 		/* From the remaining configs, choose the first one whose

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-03-27 21:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-27 21:30 [PATCH] USB config selection for RNDIS devices Ingo van Lil

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox