OpenWrt Forum Archive

Topic: Getting Sierra MC7354 modem to work with QMI on Verizon network

The content of this topic has been archived on 5 May 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

OpenWRT - Designated Driver
Modem - MC7354
Hardware - Gateworks Ventana 5220

I've dug through a bunch of other posts on qmi, this modem, and the verizon network, but still haven't been able to establish a data connection. The network settings match what uqmi reports, but I cannot ping over the network. Additionally, uqmi will initially report the connection information, then later report that the "Call failed"

I'm currently configuring the network as shown below.

config interface 'wan'
        option ifname 'wwan0'
        option proto 'qmi'
        option apn 'vzwinternet'
        option device '/dev/cdc-wdm1'

After rebooting (restarting the network doesn't seem to clean things up properly), I immediately see good network settings, but I don't ping successfully:

root@OpenWRT:~# uqmi -d /dev/cdc-wdm1 --get-current-settings
{
        "pdp-type": "ipv4-or-ipv6",
        "ip-family": "ipv4",
        "mtu": 1428,
        "ipv4": {
                "ip": "100.97.238.243",
                "dns1": "198.224.156.135",
                "dns2": "198.224.157.135",
                "gateway": "100.97.238.244",
                "subnet": "255.255.255.248"
        },
        "ipv6": {

        },
        "domain-names": {

        }
}
root@OpenWRT:~# ifconfig
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:16 errors:0 dropped:0 overruns:0 frame:0
          TX packets:16 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:1528 (1.4 KiB)  TX bytes:1528 (1.4 KiB)

wwan1     Link encap:Ethernet  HWaddr BE:2C:98:56:64:0A
          inet addr:100.97.238.243  Bcast:100.97.238.247  Mask:255.255.255.248
          inet6 addr: 2600:100c:b20c:67ed:488d:c2c3:c0eb:eb05/128 Scope:Global
          inet6 addr: fe80::bc2c:98ff:fe56:640a/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:29 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:244 (244.0 B)  TX bytes:2734 (2.6 KiB)

root@OpenWRT:~# ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
^C
--- 8.8.8.8 ping statistics ---
10 packets transmitted, 0 packets received, 100% packet loss
root@OpenWRT:~# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         100.97.238.244  0.0.0.0         UG    0      0        0 wwan1
100.97.238.240  0.0.0.0         255.255.255.248 U     0      0        0 wwan1
root@OpenWRT:~# cat /etc/resolv.conf
# Interface wan
nameserver 198.224.156.135
nameserver 198.224.157.135
nameserver 2001:4888:47:ff00:406:d::
nameserver 2001:4888:41:ff00:404:d::
root@OpenWRT:~# # wait for a minute
root@OpenWRT:~# uqmi -d /dev/cdc-wdm1 --get-current-settings
"Out of call"

Am I configuring this device correctly, or is there something special with verizon's class 3 APN that I'm not handling correctly?

Device info:
dmesg | grep -i usb

[    0.074709] usbcore: registered new interface driver usbfs
[    0.074779] usbcore: registered new interface driver hub
[    0.074864] usbcore: registered new device driver usb
[    2.185896] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    2.208152] usbcore: registered new interface driver usb-storage
[    2.214276] usbcore: registered new interface driver usbserial
[    2.220184] usbcore: registered new interface driver usbserial_generic
[    2.226785] usbserial: USB Serial support registered for generic
[    2.238616] 2184200.usb supply vbus not found, using dummy regulator
[    2.253620] ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1
[    2.276374] ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
[    2.282444] hub 1-0:1.0: USB hub found
[    2.495576] usb_otg_vbus: disabling
[    3.062001] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    3.078558] uhci_hcd: USB Universal Host Controller Interface driver
[    7.666354] usb 1-1: new high-speed USB device number 2 using ci_hdrc
[    7.817232] usb 1-1: config 1 has an invalid interface number: 8 but max is 5
[    7.824384] usb 1-1: config 1 has an invalid interface number: 10 but max is 5
[    7.831650] usb 1-1: config 1 has an invalid interface number: 11 but max is 5
[    7.838893] usb 1-1: config 1 has no interface number 1
[    7.844129] usb 1-1: config 1 has no interface number 4
[    7.849375] usb 1-1: config 1 has no interface number 5
[    9.130584] usb0: HOST MAC 36:c2:4d:3a:32:d8
[    9.134912] usb0: MAC 7a:41:79:7e:73:8c
[   20.678520] usbcore: registered new interface driver btusb
[   20.719724] usbcore: registered new interface driver cdc_acm
[   20.725389] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
[   20.734217] usbcore: registered new interface driver cdc_wdm
[   20.784967] usbcore: registered new interface driver ftdi_sio
[   20.790886] usbserial: USB Serial support registered for FTDI USB Serial Device
[   21.067039] usbcore: registered new interface driver garmin_gps
[   21.073044] usbserial: USB Serial support registered for Garmin GPS usb/tty
[   21.137069] hso: drivers/net/usb/hso.c: Option Wireless
[   21.142422] usbcore: registered new interface driver hso
[   21.529252] usbcore: registered new interface driver pl2303
[   21.534907] usbserial: USB Serial support registered for pl2303
[   21.542113] usbcore: registered new interface driver r8152
[   21.563789] usbcore: registered new interface driver sierra
[   21.569478] usbserial: USB Serial support registered for Sierra USB modem
[   21.595211] usbcore: registered new interface driver ums-alauda
[   21.601736] usbcore: registered new interface driver ums-cypress
[   21.608385] usbcore: registered new interface driver ums-datafab
[   21.614937] usbcore: registered new interface driver ums-freecom
[   21.621556] usbcore: registered new interface driver ums-isd200
[   21.628156] usbcore: registered new interface driver ums-jumpshot
[   21.634802] usbcore: registered new interface driver ums-karma
[   21.641315] usbcore: registered new interface driver ums-sddr09
[   21.647896] usbcore: registered new interface driver ums-sddr55
[   21.654436] usbcore: registered new interface driver ums-usbat
[   21.663099] usbcore: registered new interface driver usbhid
[   21.668719] usbhid: USB HID core driver
[   21.674120] usbip_core: USB/IP Core v1.0.0
[   21.679107] usbcore: registered new device driver usbip-host
[   21.684782] usbip_host: USB/IP Host Driver v1.0.0
[   21.699084] vhci_hcd vhci_hcd: USB/IP Virtual Host Controller
[   21.704856] vhci_hcd vhci_hcd: new USB bus registered, assigned bus number 2
[   21.713073] hub 2-0:1.0: USB hub found
[   21.721408] vhci_hcd: USB/IP 'Virtual' Host Controller (VHCI) Driver v1.0.0
[   21.757807] usbcore: registered new interface driver asix
[   21.764336] usbcore: registered new interface driver ath3k
[   21.781029] usbcore: registered new interface driver ath9k_htc
[   21.788857] usbcore: registered new interface driver ax88179_178a
[   21.796889] usbcore: registered new interface driver cdc_ether
[   21.805045] usbcore: registered new interface driver cdc_ncm
[   21.812156] usbcore: registered new interface driver cdc_subset
[   22.097096] usbcore: registered new interface driver huawei_cdc_ncm
[   22.122624] usbcore: registered new interface driver option
[   22.128320] usbserial: USB Serial support registered for GSM modem (1-port)
[   22.148359] usbcore: registered new interface driver qcserial
[   22.154190] usbserial: USB Serial support registered for Qualcomm USB modem
[   22.161626] qcserial 1-1:1.0: Qualcomm USB modem converter detected
[   22.168146] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB0
[   22.175401] qcserial 1-1:1.2: Qualcomm USB modem converter detected
[   22.181988] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB1
[   22.189248] qcserial 1-1:1.3: Qualcomm USB modem converter detected
[   22.195785] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB2
[   22.204773] qmi_wwan 1-1:1.8: cdc-wdm0: USB WDM device
[   22.210760] qmi_wwan 1-1:1.8 wwan0: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f
[   22.221363] qmi_wwan 1-1:1.10: cdc-wdm1: USB WDM device
[   22.227369] qmi_wwan 1-1:1.10 wwan1: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f
[   22.237776] usbcore: registered new interface driver qmi_wwan
[   22.245224] usbcore: registered new interface driver sierra_net
[   22.261590] usbcore: registered new interface driver cdc_mbim
root@OpenWRT:~#
root@OpenWRT:~# dmesg |grep -i usb
[    0.074709] usbcore: registered new interface driver usbfs
[    0.074779] usbcore: registered new interface driver hub
[    0.074864] usbcore: registered new device driver usb
[    2.185896] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    2.208152] usbcore: registered new interface driver usb-storage
[    2.214276] usbcore: registered new interface driver usbserial
[    2.220184] usbcore: registered new interface driver usbserial_generic
[    2.226785] usbserial: USB Serial support registered for generic
[    2.238616] 2184200.usb supply vbus not found, using dummy regulator
[    2.253620] ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1
[    2.276374] ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
[    2.282444] hub 1-0:1.0: USB hub found
[    2.495576] usb_otg_vbus: disabling
[    3.062001] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    3.078558] uhci_hcd: USB Universal Host Controller Interface driver
[    7.666354] usb 1-1: new high-speed USB device number 2 using ci_hdrc
[    7.817232] usb 1-1: config 1 has an invalid interface number: 8 but max is 5
[    7.824384] usb 1-1: config 1 has an invalid interface number: 10 but max is 5
[    7.831650] usb 1-1: config 1 has an invalid interface number: 11 but max is 5
[    7.838893] usb 1-1: config 1 has no interface number 1
[    7.844129] usb 1-1: config 1 has no interface number 4
[    7.849375] usb 1-1: config 1 has no interface number 5
[    9.130584] usb0: HOST MAC 36:c2:4d:3a:32:d8
[    9.134912] usb0: MAC 7a:41:79:7e:73:8c
[   20.678520] usbcore: registered new interface driver btusb
[   20.719724] usbcore: registered new interface driver cdc_acm
[   20.725389] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
[   20.734217] usbcore: registered new interface driver cdc_wdm
[   20.784967] usbcore: registered new interface driver ftdi_sio
[   20.790886] usbserial: USB Serial support registered for FTDI USB Serial Device
[   21.067039] usbcore: registered new interface driver garmin_gps
[   21.073044] usbserial: USB Serial support registered for Garmin GPS usb/tty
[   21.137069] hso: drivers/net/usb/hso.c: Option Wireless
[   21.142422] usbcore: registered new interface driver hso
[   21.529252] usbcore: registered new interface driver pl2303
[   21.534907] usbserial: USB Serial support registered for pl2303
[   21.542113] usbcore: registered new interface driver r8152
[   21.563789] usbcore: registered new interface driver sierra
[   21.569478] usbserial: USB Serial support registered for Sierra USB modem
[   21.595211] usbcore: registered new interface driver ums-alauda
[   21.601736] usbcore: registered new interface driver ums-cypress
[   21.608385] usbcore: registered new interface driver ums-datafab
[   21.614937] usbcore: registered new interface driver ums-freecom
[   21.621556] usbcore: registered new interface driver ums-isd200
[   21.628156] usbcore: registered new interface driver ums-jumpshot
[   21.634802] usbcore: registered new interface driver ums-karma
[   21.641315] usbcore: registered new interface driver ums-sddr09
[   21.647896] usbcore: registered new interface driver ums-sddr55
[   21.654436] usbcore: registered new interface driver ums-usbat
[   21.663099] usbcore: registered new interface driver usbhid
[   21.668719] usbhid: USB HID core driver
[   21.674120] usbip_core: USB/IP Core v1.0.0
[   21.679107] usbcore: registered new device driver usbip-host
[   21.684782] usbip_host: USB/IP Host Driver v1.0.0
[   21.699084] vhci_hcd vhci_hcd: USB/IP Virtual Host Controller
[   21.704856] vhci_hcd vhci_hcd: new USB bus registered, assigned bus number 2
[   21.713073] hub 2-0:1.0: USB hub found
[   21.721408] vhci_hcd: USB/IP 'Virtual' Host Controller (VHCI) Driver v1.0.0
[   21.757807] usbcore: registered new interface driver asix
[   21.764336] usbcore: registered new interface driver ath3k
[   21.781029] usbcore: registered new interface driver ath9k_htc
[   21.788857] usbcore: registered new interface driver ax88179_178a
[   21.796889] usbcore: registered new interface driver cdc_ether
[   21.805045] usbcore: registered new interface driver cdc_ncm
[   21.812156] usbcore: registered new interface driver cdc_subset
[   22.097096] usbcore: registered new interface driver huawei_cdc_ncm
[   22.122624] usbcore: registered new interface driver option
[   22.128320] usbserial: USB Serial support registered for GSM modem (1-port)
[   22.148359] usbcore: registered new interface driver qcserial
[   22.154190] usbserial: USB Serial support registered for Qualcomm USB modem
[   22.161626] qcserial 1-1:1.0: Qualcomm USB modem converter detected
[   22.168146] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB0
[   22.175401] qcserial 1-1:1.2: Qualcomm USB modem converter detected
[   22.181988] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB1
[   22.189248] qcserial 1-1:1.3: Qualcomm USB modem converter detected
[   22.195785] usb 1-1: Qualcomm USB modem converter now attached to ttyUSB2
[   22.204773] qmi_wwan 1-1:1.8: cdc-wdm0: USB WDM device
[   22.210760] qmi_wwan 1-1:1.8 wwan0: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f
[   22.221363] qmi_wwan 1-1:1.10: cdc-wdm1: USB WDM device
[   22.227369] qmi_wwan 1-1:1.10 wwan1: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f
[   22.237776] usbcore: registered new interface driver qmi_wwan
[   22.245224] usbcore: registered new interface driver sierra_net
[   22.261590] usbcore: registered new interface driver cdc_mbim

cat /sys/kernel/debug/usb/devices

T:  Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480  MxCh= 8
B:  Alloc=  0/800 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=1d6b ProdID=0002 Rev= 4.04
S:  Manufacturer=Linux 4.4.0 vhci_hcd
S:  Product=USB/IP Virtual Host Controller
S:  SerialNumber=vhci_hcd
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

T:  Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480  MxCh= 1
B:  Alloc=  0/800 us ( 0%), #Int=  1, #Iso=  0
D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=1d6b ProdID=0002 Rev= 4.04
S:  Manufacturer=Linux 4.4.0 ehci_hcd
S:  Product=EHCI Host Controller
S:  SerialNumber=ci_hdrc.1
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=480  MxCh= 0
D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=1199 ProdID=68c0 Rev= 0.06
S:  Manufacturer=Sierra Wireless, Incorporated
S:  Product=MC7354
C:* #Ifs= 6 Cfg#= 1 Atr=e0 MxPwr=500mA
I:* If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=qcserial
E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=qcserial
E:  Ad=83(I) Atr=03(Int.) MxPS=  12 Ivl=32ms
E:  Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=qcserial
E:  Ad=85(I) Atr=03(Int.) MxPS=  12 Ivl=32ms
E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 8 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#=10 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
E:  Ad=89(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
E:  Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#=11 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E:  Ad=8b(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
E:  Ad=8a(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=06(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

ls -l /dev/cdc-wdm*

crw-r--r--    1 root     root      180, 176 Aug 15 17:52 /dev/cdc-wdm0
crw-r--r--    1 root     root      180, 177 Aug 15 17:52 /dev/cdc-wdm1

lsmod

6lowpan                 7370  1 bluetooth_6lowpan
act_connmark            1873  0
act_mirred              2710  0
act_skbedit             1870  0
aead                    3746  6 cryptodev
ahci                   12443  0
asix                   16584  0
ath                    17488  6 ath9k
ath10k_core           212215  1 ath10k_pci
ath10k_pci             25979  0
ath3k                   6253  0
ath5k                 146322  0
ath9k                  88439  0
ath9k_common           19035  2 ath9k
ath9k_htc              51536  0
ath9k_hw              380532  3 ath9k
authenc                 3560  1 caamalg
ax88179_178a           12356  0
batman_adv            118149  0
bluetooth             241006 10 ath3k
bluetooth_6lowpan       8375  0
bnep                    8656  0
bonding                87958  0
btintel                 5432  1 btusb
btusb                  22410  0
caam                    6404  0
caam_jr                12539  3 caamrng
caamalg                48782  0
caamhash               26897  0
caamrng                 2722  0
can                    24018  3 can_raw
can_bcm                10708  0
can_dev                 8404  1 flexcan
can_gw                  7186  0
can_raw                 5957  0
ccm                     6777  0
cdc_acm                13791  0
cdc_ether               3429  0
cdc_mbim                4236  0
cdc_ncm                12483  2 cdc_mbim
cdc_subset              1838  0
cdc_wdm                 8034  4 cdc_mbim
cfg80211              373878 10 ath9k
cls_flow                5456  0
cls_fw                  3739  0
cls_route               4867  0
cls_tcindex             4770  0
cls_u32                 6607  0
cmac                    2413  0
compat                  3012 10 ath9k
configfs               18887  8 usb_f_acm
configs                23894  0
crc_ccitt               1195  1 ppp_async
crypto_null             2785  3 gcm
cryptodev              30466  0
ctr                     3168  0
drbg                   12597  0
dsa_core               14786  1 mv88e6xxx_drv
e1000                  87009  0
e1000e                141136  0
ebt_802_3               1008  0
ebt_among               2288  0
ebt_arp                 1772  0
ebt_arpreply            1270  0
ebt_dnat                1006  0
ebt_ip                  1514  0
ebt_ip6                 1900  0
ebt_limit               1140  0
ebt_mark                 942  0
ebt_mark_m               878  0
ebt_pkttype              820  0
ebt_redirect            1014  0
ebt_snat                1070  0
ebt_stp                 2028  0
ebt_vlan                1198  0
ebtable_broute          1089  0
ebtable_filter          1253  0
ebtable_nat             1248  0
ebtables               14867  3 ebtable_nat
ecb                     1697  0
em_u32                   845  0
evdev                  10211  0
fat                    44522  1 vfat
flexcan                 7058  0
ftdi_sio               28881  0
g_ether                 2986  0
garmin_gps              6541  0
gcm                     9402  0
gf128mul                5732  1 ghash_generic
ghash_generic           1664  0
gpio_button_hotplug     5956  0
grace                   1336  1 lockd
gre                     1314  1 ip_gre
gsc_hwmon               3315  0
gsc_input               2191  0
gw16083                 8339  0
hci_uart               12124  0
hid                    73744  3 usbhid
hid_generic              816  0
hidp                   11245  0
hmac                    2440  0
hso                    23414  0
huawei_cdc_ncm          1827  0
hwmon                   2270  1 gsc_hwmon
i2c_algo_bit            4560  1 igb
ifb                     3240  0
igb                   124057  0
input_core             24471 12 mma8451
input_polldev           2893  1 mma8451
ip6_tables              9813  3 ip6table_raw
ip6t_REJECT             1132  0
ip6table_filter          894  0
ip6table_mangle         1278  1
ip6table_raw             888  0
ip_gre                  9160  0
ip_tables              10071  4 iptable_nat
ip_tunnel              10704  1 ip_gre
ipt_ECN                 1572  0
ipt_MASQUERADE           946  0
ipt_REJECT              1130  0
iptable_filter           956  0
iptable_mangle          1084  1
iptable_nat             1233  0
iptable_raw              950  0
iwldvm                103002  0
iwlmvm                164206  0
iwlwifi                95635  2 iwlmvm
jitterentropy_rng       5854  0
leds_gpio               2923  0
ledtrig_gpio            2404  0
ledtrig_heartbeat       1729  0
ledtrig_morse           2017  0
ledtrig_usbdev          2531  0
libcomposite           29603  7 usb_f_acm
libcrc32c                779  1 batman_adv
lockd                  48547  3 nfsd
loop                   13822  0
lsm9ds1_acc_gyr        15309  0
lsm9ds1_mag             9530  0
mac80211              485348  6 ath9k
mii                     3416  4 ax88179_178a
mma8451                 4883  0
mv88e6xxx_drv          18593  0
nf_conntrack           52096 17 nf_nat_ipv6
nf_conntrack_ftp        5479  1 nf_nat_ftp
nf_conntrack_ipv4       5443  4
nf_conntrack_ipv6       5756  4
nf_conntrack_rtcache    2770  0
nf_defrag_ipv4          1148  1 nf_conntrack_ipv4
nf_defrag_ipv6         13469  1 nf_conntrack_ipv6
nf_log_common           2575  2 nf_log_ipv4
nf_log_ipv4             3254  0
nf_log_ipv6             3447  0
nf_nat                  8615  7 nf_nat_ipv6
nf_nat_ftp              1444  0
nf_nat_ipv4             3591  1 iptable_nat
nf_nat_ipv6             3791  0
nf_nat_masquerade_ipv4    1677  1 ipt_MASQUERADE
nf_nat_redirect         1115  1 xt_REDIRECT
nf_reject_ipv4          2115  1 ipt_REJECT
nf_reject_ipv6          2440  1 ip6t_REJECT
nfs                   132328  1 nfsv3
nfsd                   71078  0
nfsv3                  16505  0
nls_iso8859_1           3170  0
ntfs                   76210  0
ohci_hcd               21691  1 ohci_platform
ohci_platform           3656  0
option                 27057  0
pl2303                  6976  0
ppp_async               6609  0
ppp_generic            19821  3 pppoe
pppoe                   7927  0
pppox                   1511  1 pppoe
pps_gpio                2324  0
qcserial                4669  0
qmi_wwan               10790  0
r8152                  26830  0
rfcomm                 26980  0
rfkill                 12029  2 hso
rng_core                4972  1 caamrng
sch_hfsc               11951  0
sch_ingress             1281  0
seqiv                   2677  0
sha256_generic          8792  0
sierra                  6636  0
sierra_net              5878  0
sky2                   42909  0
slcan                   4719  0
slhc                    4178  1 ppp_generic
spidev                  5764  0
sunrpc                176215  4 nfsd
ts_bm                   1634  0
ts_fsm                  2726  0
ts_kmp                  1510  0
tun                    15361  0
u_ether                 8623  4 usb_f_ncm
u_serial                7776  1 usb_f_acm
uhci_hcd               17576  0
ums_alauda              8305  0
ums_cypress             2680  0
ums_datafab             4696  0
ums_freecom             2356  0
ums_isd200              5612  0
ums_jumpshot            3803  0
ums_karma               1972  0
ums_sddr09              8784  0
ums_sddr55              5367  0
ums_usbat               7201  0
usb_f_acm               3948  0
usb_f_ecm               5000  1
usb_f_hid               7533  0
usb_f_mass_storage     24263  0
usb_f_ncm               8870  0
usb_f_rndis            10223  2 g_ether
usb_wwan                4376  2 qcserial
usbhid                 21700  0
usbip_core              4362  2 vhci_hcd
usbip_host             11178  0
usbnet                 16129  9 cdc_mbim
vcan                    1799  0
vfat                    7890  0
vhci_hcd               12475  0
x_tables               10153 60 ipt_REJECT
xt_CLASSIFY              844  0
xt_CT                   2965  0
xt_DSCP                 1646  0
xt_HL                   1560  0
xt_LED                  1640  0
xt_LOG                  1091  0
xt_NETMAP               1517  0
xt_REDIRECT             1077  0
xt_TCPMSS               2792  0
xt_comment               715 10
xt_connbytes            1557  0
xt_connlimit            4501  0
xt_connmark             1396  6
xt_conntrack            2584  0
xt_dscp                 1302  0
xt_ecn                  1564  0
xt_helper               1100  0
xt_hl                   1118  0
xt_id                    710  0
xt_length                997  2
xt_limit                1293  0
xt_mac                   839  0
xt_mark                  928 36
xt_multiport            1492 10
xt_nat                  1565  0
xt_recent               6492  0
xt_state                1033  0
xt_statistic            1109  0
xt_string               1036  0
xt_tcpmss               1226  0
xt_tcpudp               2008 14
xt_time                 1830  0

Any help would be greatly appreciated!

ssparks wrote:

I'm currently configuring the network as shown below.

config interface 'wan'
        option ifname 'wwan0'
        option proto 'qmi'
        option apn 'vzwinternet'
        option device '/dev/cdc-wdm1'

..

[   22.204773] qmi_wwan 1-1:1.8: cdc-wdm0: USB WDM device
[   22.210760] qmi_wwan 1-1:1.8 wwan0: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f
[   22.221363] qmi_wwan 1-1:1.10: cdc-wdm1: USB WDM device
[   22.227369] qmi_wwan 1-1:1.10 wwan1: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, ee:3e:f6:cd:a4:0f

cdc-wdm0 and wwan0 are connected to USB interface 8.  cdc-wdm1 and wwan1 are connected to USB interface 10.  These are two separate QMI functions provided by the modem.  You cannot mix and match. cdc-wdm1 controls wwan1, not wwan0.

Your dmesg log makes the relationship clear. And it will not change since these interfaces belong to the same USB device.  But if you want to be 110% safe and do the lookup dynamically, you can use sysfs to map back and forthe between cdc-wdm and wwan devices.  E.g


ls /sys/class/net/wwan0/device/usbmisc/
ls /sys/class/usbmisc/cdc-wdm0/device/net/
bmork wrote:

cdc-wdm0 and wwan0 are connected to USB interface 8.  cdc-wdm1 and wwan1 are connected to USB interface 10.  These are two separate QMI functions provided by the modem.  You cannot mix and match. cdc-wdm1 controls wwan1, not wwan0.

Thanks for the info, bmork. I've reconfigured my network settings to make sure these match. I also added logging to /lib/netifd/proto/qmi.sh so I can see how far we are getting.

I've updated my configuration to disable ipv6 and wait for 90 seconds to ensure the usb connection is stable. For wdm0, this looks like:

config interface 'wan'
        option ifname 'wwan0'
        option proto 'qmi'
        option apn 'vzwinternet'
        option device '/dev/cdc-wdm0'
        option delay '90'
        option ipv6 0

My debug statements show a failure to start the network:

Wed Aug 16 13:30:01 2017 daemon.notice netifd: Interface 'loopback' is enabled
Wed Aug 16 13:30:01 2017 daemon.notice netifd: Interface 'loopback' is setting up now
Wed Aug 16 13:30:01 2017 daemon.notice netifd: Interface 'loopback' is now up
Wed Aug 16 13:30:01 2017 daemon.notice netifd: Interface 'wan' is setting up now
Wed Aug 16 13:30:01 2017 daemon.notice netifd: Network device 'lo' link is up
Wed Aug 16 13:30:01 2017 daemon.notice netifd: Interface 'loopback' has link connectivity
Wed Aug 16 13:30:01 2017 daemon.notice netifd: wan (2510): XXX - ifname=wwan0
Wed Aug 16 13:30:01 2017 daemon.notice netifd: wan (2510): XXX - sleeping for 90
Wed Aug 16 13:31:31 2017 daemon.notice netifd: wan (2510): XXX - uqmi -s -d /dev/cdc-wdm0 --get-pin-status
Wed Aug 16 13:31:31 2017 daemon.notice netifd: wan (2510): XXX -  uqmi -s -d /dev/cdc-wdm0 --set-data-format 802.3
Wed Aug 16 13:31:31 2017 daemon.notice netifd: wan (2510): XXX -  uqmi -s -d /dev/cdc-wdm0 --wda-set-data-format 802.3
Wed Aug 16 13:31:31 2017 daemon.notice netifd: wan (2510): Waiting for network registration
Wed Aug 16 13:31:31 2017 daemon.notice netifd: wan (2510): Starting network vzwinternet
Wed Aug 16 13:31:32 2017 daemon.notice netifd: wan (2510): XXX - cid_4 is 8
Wed Aug 16 13:31:32 2017 daemon.notice netifd: wan (2510): XXX -  uqmi -s -d /dev/cdc-wdm0 --set-client-id wds,8 --start-network vzwinternet    --ip-family ipv4
Wed Aug 16 13:31:32 2017 daemon.notice netifd: wan (2510): Unable to connect IPv4: "No effect"

Oddly enough, when I configure ifname to wwan1 and device to /dev/cdc-wdm1, I get a different error:

Wed Aug 16 13:35:41 2017 daemon.notice netifd: Interface 'loopback' is enabled
Wed Aug 16 13:35:41 2017 daemon.notice netifd: Interface 'loopback' is setting up now
Wed Aug 16 13:35:41 2017 daemon.notice netifd: Interface 'loopback' is now up
Wed Aug 16 13:35:41 2017 daemon.notice netifd: Interface 'wan' is setting up now
Wed Aug 16 13:35:41 2017 daemon.notice netifd: Network device 'lo' link is up
Wed Aug 16 13:35:41 2017 daemon.notice netifd: Interface 'loopback' has link connectivity
Wed Aug 16 13:35:41 2017 daemon.notice netifd: wan (2508): XXX - ifname=wwan1
Wed Aug 16 13:35:41 2017 daemon.notice netifd: wan (2508): XXX - sleeping for 90
Wed Aug 16 13:37:11 2017 daemon.notice netifd: wan (2508): XXX - uqmi -s -d /dev/cdc-wdm1 --get-pin-status
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): XXX -  uqmi -s -d /dev/cdc-wdm1 --set-data-format 802.3
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): XXX -  uqmi -s -d /dev/cdc-wdm1 --wda-set-data-format 802.3
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): Waiting for network registration
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): Starting network vzwinternet
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): XXX - cid_4 is 8
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): XXX -  uqmi -s -d /dev/cdc-wdm1 --set-client-id wds,8 --start-network vzwinternet    --ip-family ipv4
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): Unable to connect IPv4: "Call failed"

In neither case does ifconfig show any network settings.
Note, also, that I am pulling power between tests to ensure a consistent initial state

ssparks wrote:
Wed Aug 16 13:31:32 2017 daemon.notice netifd: wan (2510): XXX -  uqmi -s -d /dev/cdc-wdm0 --set-client-id wds,8 --start-network vzwinternet    --ip-family ipv4
Wed Aug 16 13:31:32 2017 daemon.notice netifd: wan (2510): Unable to connect IPv4: "No effect"

Which means that the modem is already connected, probably because "autoconnect" is enabled.  This confuses the script. 

Oddly enough, when I configure ifname to wwan1 and device to /dev/cdc-wdm1, I get a different error:

Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): XXX -  uqmi -s -d /dev/cdc-wdm1 --set-client-id wds,8 --start-network vzwinternet    --ip-family ipv4
Wed Aug 16 13:37:12 2017 daemon.notice netifd: wan (2508): Unable to connect IPv4: "Call failed"

My best guess is that this connection is denied by the operator because the same modem and APN is already connected.  If you have aother valid APN, then you could try connecting that.   But the real solution is to disable autoconnect.  With a recent enough uqmi (unsure which version is in DD...), you can do this with


uqmi -d  /dev/cdc-wdm0 --set-autoconnect

In addtion to confusing the scripts, autoconnect will also often cause the modem to use raw-ip mode.  Which will be a problem in DD.

In neither case does ifconfig show any network settings.
Note, also, that I am pulling power between tests to ensure a consistent initial state

That's smart.  But settings like autoconnect are persistently stored in nvram on the modem.

bmork wrote:

With a recent enough uqmi (unsure which version is in DD...), you can do this with


uqmi -d  /dev/cdc-wdm0 --set-autoconnect

I'm using uqmi PKG_VERSION 2015-09-17, which is the latest version hosted on the github OpenWRT master branch (github.com/openwrt/openwrt/blob/master/package/network/utils/uqmi/Makefile).

It has this option requiring an argument, so i did the following:

root@OpenWRT:~# uqmi -d /dev/cdc-wdm0 --set-autoconnect disabled
root@OpenWRT:~# uqmi -d /dev/cdc-wdm1 --set-autoconnect disabled

After a reboot, netifd hung on the qmi.sh while loop waiting for --get-pin-status. After waiting 5 minutes, I ran from the command line:

root@OpenWRT:~# uqmi -s -d /dev/cdc-wdm0 --get-pin-status
"UIM uninitialized"

Note the same thing happened when I switch to /dev/cdc-wdm1. Do I need to do something to disable pin usage, or does this message mean something else?


bmork wrote:

That's smart.  But settings like autoconnect are persistently stored in nvram on the modem.

Woah. That explains some of the odd behavior I've been seeing. Thanks for your help on this!

ssparks wrote:

I'm using uqmi PKG_VERSION 2015-09-17, which is the latest version hosted on the github OpenWRT master branch (github.com/openwrt/openwrt/blob/master/package/network/utils/uqmi/Makefile).

It has this option requiring an argument, so i did the following:

root@OpenWRT:~# uqmi -d /dev/cdc-wdm0 --set-autoconnect disabled
root@OpenWRT:~# uqmi -d /dev/cdc-wdm1 --set-autoconnect disabled

Right.  I just forgot the argument in my example :-)

After a reboot, netifd hung on the qmi.sh while loop waiting for --get-pin-status. After waiting 5 minutes, I ran from the command line:

root@OpenWRT:~# uqmi -s -d /dev/cdc-wdm0 --get-pin-status
"UIM uninitialized"

Note the same thing happened when I switch to /dev/cdc-wdm1. Do I need to do something to disable pin usage, or does this message mean something else?

Odd.  I don't think you should need to do anything special.  Why did't you get this message before?  If you have a SIM with PIN enabled, then it should have failed to autoconnect too.  Sorry, I don't have any suggestions here.  Except maybe try another time and hope it was just a glitch.

bmork wrote:

Odd.  I don't think you should need to do anything special.  Why did't you get this message before?  If you have a SIM with PIN enabled, then it should have failed to autoconnect too.  Sorry, I don't have any suggestions here.  Except maybe try another time and hope it was just a glitch.

ugh. I pulled the sim out of the device, and used it with another (non-qmi) based modem, and it works fine.
After putting it back in this device with this modem, I tried re-enabling autoconnect, and I am unable to get this command to return anything besides "UIM uninitialized" :-(

ssparks wrote:

I'm using uqmi PKG_VERSION 2015-09-17, which is the latest version hosted on the github OpenWRT master branch (github.com/openwrt/openwrt/blob/master/package/network/utils/uqmi/Makefile).

A 2 year old uqmi, that is way too old.
Either get a modern one from LEDE or wait until OpenWrt and LEDE has re-merged.
MC7354 needs qmi raw as far as I know and that was added in uqmi less than a year ago.

Lars Melin wrote:

MC7354 needs qmi raw as far as I know and that was added in uqmi less than a year ago.

No, the MC7354 should also work in 802.3 mode. But I agree that it often is easier to make it work in raw-ip mode due to modem firmware restrictions/bugs.  But that is only true when raw-ip support is readily available on the host side...

Note that the primary show-stopper for raw-ip support in OpenWrt/LEDE is the qmi_wwan driver version, not the uqmi version. The  'wda-get/set-data-format' requests were added in 2014. But you need a v4.5 or newer kernel to get a driver with support for raw-ip framing.  Which means that this isn't available in any released OpwnWrt or LEDE version - yet.

bmork wrote:
Lars Melin wrote:

MC7354 needs qmi raw as far as I know and that was added in uqmi less than a year ago.

No, the MC7354 should also work in 802.3 mode. But I agree that it often is easier to make it work in raw-ip mode due to modem firmware restrictions/bugs.  But that is only true when raw-ip support is readily available on the host side...

This modem does appear to work fine in 802.3 mode. The issue here is the autoconnect. If autoconnect is enabled (default if no autoconnect option exists) then this modem will return the 'NoEffect' on connect which makes qmi.sh error/retry endlessly. What was misleading is that the first boot would work fine if the modem wasn't in autoconnect mode but subsequent boots would not.

Furthermore I've found that 'uqmi --set-autoconnect' does not work (at least for this modem) to enable or disable autoconnect yet enabling autoconnect with the '--autoconnect' to the '--start-network' and disabling it with the '--autoconnect' on '--stop-network' does. This was tested on LEDE with uqmi PKG_VERSION 2016-12-19

I'm curious why autoconnect doesn't break other QMI modems? Perhaps it does?

So with the following configuration LEDE with the MC7354 is now working for me:
config interface 'wan'
        option ifname 'wwan0'
        option proto 'qmi'
        option apn 'm2m.com.attz'
        option device '/dev/cdc-wdm0'
        option autoconnect '0'

The key was to disable autoconnect

Tim

tharvey wrote:

I'm curious why autoconnect doesn't break other QMI modems? Perhaps it does?

I believe it does. At least I've never been able to co-operate with the firmware when it does autoconnect. See for example https://dev.openwrt.org/ticket/16724

The connection should be managed by the host, IMHO.  But that's my personal view.  I believe the OpenWrt devs see it differently. Ref
https://git.lede-project.org/?p=source. … 7cdfe2df06
https://git.lede-project.org/?p=source. … 99cd9cbc18

And they do have a point. uqmi isn't a connection manager.

@tharvy - confirmed. I was able to use LEDE and the wwan was successfully established. Thanks

The discussion might have continued from here.