USB: qcserial: Fix support for HP lt4112 LTE/HSPA+ Gobi 4G Modem
authorBjørn Mork <bjorn@mork.no>
Mon, 16 Nov 2015 12:15:46 +0000 (13:15 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Dec 2015 19:31:23 +0000 (14:31 -0500)
commitc5eb38c5d23946f2a139eb4534681f093decdd97
tree247795a4b6cd85846c163e04b8b6105be9ad0512
parent9fe488e4b2b293457a5ab1ac4bcacc15754649b1
USB: qcserial: Fix support for HP lt4112 LTE/HSPA+ Gobi 4G Modem

commit 59536da34513c594af2a6fd35ba65ea45b6960a1 upstream.

The DEVICE_HWI type was added under the faulty assumption that Huawei
devices based on Qualcomm chipsets and firmware use the static USB
interface numbering known from Gobi devices.  But this model does
not apply to Huawei devices like the HP branded lt4112 (Huawei me906e).
Huawei firmwares will dynamically assign interface numbers. Functions
are renumbered when the firmware is reconfigured.

Fix by changing the DEVICE_HWI type to use a simplified version
of Huawei's subclass + protocol scheme: Blacklisting known network
interface combinations and assuming the rest are serial.

Reported-and-tested-by: Muri Nicanor <muri+libqmi@immerda.ch>
Tested-by: Martin Hauke <mardnh@gmx.de>
Fixes: e7181d005e84 ("USB: qcserial: Add support for HP lt4112 LTE/HSPA+ Gobi 4G Modem")
Signed-off-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/qcserial.c