Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

cdc_mbim: apply "NDP to end" quirk to all Huawei devices

We now have a positive report of another Huawei device needing
this quirk: The ME906s-158 (12d1:15c1). This is an m.2 form
factor modem with no obvious relationship to the E3372 (12d1:157d)
we already have a quirk entry for. This is reason enough to
believe the quirk might be necessary for any number of current
and future Huawei devices.

Applying the quirk to all Huawei devices, since it is crucial
to any device affected by the firmware bug, while the impact
on non-affected devices is negligible.

The quirk can if necessary be disabled per-device by writing
N to /sys/class/net/<iface>/cdc_ncm/ndp_to_end

Reported-by: Andreas Fett <andreas.fett@secunet.com>
Signed-off-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Bjørn Mork and committed by
David S. Miller
c5b5343c b4dfd8e9

+7 -2
+7 -2
drivers/net/usb/cdc_mbim.c
··· 617 617 { USB_VENDOR_AND_INTERFACE_INFO(0x0bdb, USB_CLASS_COMM, USB_CDC_SUBCLASS_MBIM, USB_CDC_PROTO_NONE), 618 618 .driver_info = (unsigned long)&cdc_mbim_info, 619 619 }, 620 - /* Huawei E3372 fails unless NDP comes after the IP packets */ 621 - { USB_DEVICE_AND_INTERFACE_INFO(0x12d1, 0x157d, USB_CLASS_COMM, USB_CDC_SUBCLASS_MBIM, USB_CDC_PROTO_NONE), 620 + 621 + /* Some Huawei devices, ME906s-158 (12d1:15c1) and E3372 622 + * (12d1:157d), are known to fail unless the NDP is placed 623 + * after the IP packets. Applying the quirk to all Huawei 624 + * devices is broader than necessary, but harmless. 625 + */ 626 + { USB_VENDOR_AND_INTERFACE_INFO(0x12d1, USB_CLASS_COMM, USB_CDC_SUBCLASS_MBIM, USB_CDC_PROTO_NONE), 622 627 .driver_info = (unsigned long)&cdc_mbim_info_ndp_to_end, 623 628 }, 624 629 /* default entry */