All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo van Lil <inguin@gmx.de>
To: linux-kernel@vger.kernel.org
Subject: [PATCH] USB config selection for RNDIS devices
Date: Tue, 27 Mar 2007 23:30:12 +0200	[thread overview]
Message-ID: <46098CE4.5060907@gmx.de> (raw)

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

                 reply	other threads:[~2007-03-27 21:30 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46098CE4.5060907@gmx.de \
    --to=inguin@gmx.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.