Bug 205807
Summary: | Softbank 403ZT (ZTE) modem support | ||
---|---|---|---|
Product: | Drivers | Reporter: | ___ (lockywolf) |
Component: | USB | Assignee: | drivers_network-wireless (drivers_network-wireless) |
Status: | NEW --- | ||
Severity: | normal | CC: | larsm17, schoolsag |
Priority: | P1 | ||
Hardware: | x86-64 | ||
OS: | Linux | ||
URL: | http://www.draisberghof.de/usb_modeswitch/bb/viewtopic.php?f=2&t=2914&p=19459#p19459 | ||
Kernel Version: | 5.4.2 | Subsystem: | |
Regression: | No | Bisected commit-id: |
Description
___
2019-12-09 05:03:47 UTC
After trying for some more time, I still have this bug. The modem is detected correctly with probability of about 50% if inserted before booting the system. It is always detected incorrectly if inserted into a running system. All debugging suggestions welcome. After consulting the author of usb_modeswitch, he suggested that either option.ko, or qmi_wwan.ko can to be updated with the support for this modem if working as a usb_id 19d2:1282 The device in question is a Softbank 435ZT branded ZTE modem which if not manually mode switched will automatically switch to 19d2:0017 which is a ZTE debug & firmware download id. The user has in the past relied on this automatic mode switch but the device is now included for switching in the latest usb_modeswitch where it gets switched to 19d2:1282, an id which has been confirmed to be correct by checking the Windows drivers from Softbank. 19d2:1282 was included in linux option driver in commit a71ee85e1d74e862d68cc9b2f2ab6a806d2550c9 from 2010-07-05, a commit which adds a whole bunch of id's which ZTE anticipated that they would use in the future. Unfortunately most (all?) of them are incorrect and many of them has been corrected over the years - none of them initially excluded the net interface and all of them have the class/subclass/proto attributes of ff/ff/ff which is wrong for many of them. 19d2:1282 has the following interface layout according to Win drivers and attributes according to users verbose lsusb listing: MI_00 ZTE Diagnostics Device (ff/ff/ff) MI_01 ZTE UI AT Interface (ff/00/00) MI_02 ZTE Proprietary USB Modem (ff/00/00) MI_03 ZTE Wireless Ethernet Adapter (ff/ff/ff , qmi_wwan) MI_04 USB Mass Storage Device (08/06/50) The option driver needs to be corrected so it only supports interface 1 and 2. The net interface should then be added into the qmi_wwan driver. Softbank 403ZT it is, not 435ZT. I have tested the following patch on Linux kernel version 4.14.180 (OpenWRT 19.07.3 on ARMv7 architecture) diff --git a/qmi_wwan.c b/qmi_wwan.c --- a/qmi_wwan.c +++ b/qmi_wwan.c @@ -1279,6 +1279,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x19d2, 0x1255, 4)}, {QMI_FIXED_INTF(0x19d2, 0x1256, 4)}, {QMI_FIXED_INTF(0x19d2, 0x1270, 5)}, /* ZTE MF667 */ + {QMI_FIXED_INTF(0x19d2, 0x1282, 3)}, /* ZTE MF833V */ {QMI_FIXED_INTF(0x19d2, 0x1401, 2)}, {QMI_FIXED_INTF(0x19d2, 0x1402, 2)}, /* ZTE MF60 */ {QMI_FIXED_INTF(0x19d2, 0x1424, 2)}, -- 2.17.1 It worked flawless and now I'm able to use the cdc-wdm interface with ease in OpenWRT qmi wrapper and uqmi binary Logs from the router: dmesg: [ 20.071280] usb 2-1: new high-speed USB device number 3 using xhci-hcd [ 20.265565] option 2-1:1.0: GSM modem (1-port) converter detected [ 20.271803] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB0 [ 20.278873] option 2-1:1.1: GSM modem (1-port) converter detected [ 20.285147] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB1 [ 20.292260] option 2-1:1.2: GSM modem (1-port) converter detected [ 20.293785] ieee80211 phy1: change: 0x100 [ 20.298518] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB2 [ 20.309955] qmi_wwan 2-1:1.3: cdc-wdm0: USB WDM device lsusb: Bus 002 Device 003: ID 19d2:1282 ZTE WCDMA Technologies MSM uqmi -d /dev/cdc-wdm0 --get-capabilities { "max_tx_channel_rate": 50000000, "max_rx_channel_rate": 100000000, "data_service": "non_simultaneous_cs_ps", "sim": "supported", "networks": [ "gsm", "umts", "lte" ] } |