diff mbox

[net-next] net: qmi_wwan: ignore bogus CDC Union descriptors

Message ID 1450352644-12445-1-git-send-email-bjorn@mork.no
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

Bjørn Mork Dec. 17, 2015, 11:44 a.m. UTC
The CDC descriptors found on these vendor specific functions should
not be considered authoritative.  They seem to be ignored by drivers
for other systems, and the quality is therefore low.

One device (1e0e:9001) has been reported to have such a bogus union
descriptor on the QMI function, making it fail probing even if the
device id was dynamically added.  The report was not complete enough
to allow adding a device entry for this modem. But this should at
least fix the dynamic id probing problem.

Reported-by: Kanerva Topi <Topi.Kanerva@cinia.fi>
Signed-off-by: Bjørn Mork <bjorn@mork.no>
---
 drivers/net/usb/qmi_wwan.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

David Miller Dec. 17, 2015, 9:11 p.m. UTC | #1
From: Bjørn Mork <bjorn@mork.no>
Date: Thu, 17 Dec 2015 12:44:04 +0100

> The CDC descriptors found on these vendor specific functions should
> not be considered authoritative.  They seem to be ignored by drivers
> for other systems, and the quality is therefore low.
> 
> One device (1e0e:9001) has been reported to have such a bogus union
> descriptor on the QMI function, making it fail probing even if the
> device id was dynamically added.  The report was not complete enough
> to allow adding a device entry for this modem. But this should at
> least fix the dynamic id probing problem.
> 
> Reported-by: Kanerva Topi <Topi.Kanerva@cinia.fi>
> Signed-off-by: Bjørn Mork <bjorn@mork.no>

Applied, thanks!
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/net/usb/qmi_wwan.c b/drivers/net/usb/qmi_wwan.c
index 6f3bf75147e2..ad1f7dfac590 100644
--- a/drivers/net/usb/qmi_wwan.c
+++ b/drivers/net/usb/qmi_wwan.c
@@ -374,7 +374,10 @@  static int qmi_wwan_bind(struct usbnet *dev, struct usb_interface *intf)
 				"bogus CDC Union: master=%u, slave=%u\n",
 				cdc_union->bMasterInterface0,
 				cdc_union->bSlaveInterface0);
-			goto err;
+
+			/* ignore and continue... */
+			cdc_union = NULL;
+			info->data = intf;
 		}
 	}