Failed to build drivers for Quectel EC25 Mini PCle 4G/LTE Module


Quectel EC25 Mini PCle 4G/LTE Module – EC25
Raspberry Pi 3G-4G/LTE Base Shield V2
Kernel: 4.19.42-v7

This kernel already has the QMI interface but running sudo ./quectel-CM -s fails with a no lease message.

The make for the driver provided fails too, log below. Please provide an updated version.

root@raspberrypi:/home/pi/files/drivers# make
rm -rf *~ .tmp_versions modules.order Module.symvers
find . -type f -name *~ -o -name *.o -o -name *.ko -o -name *.cmd -o -name *.mod.c |  xargs rm -rf
make -C /lib/modules/4.19.42-v7+/build M=/home/pi/files/drivers modules
make[1]: Entering directory '/usr/src/linux-headers-4.19.42-v7+'
  CC [M]  /home/pi/files/drivers/./drivers/usb/serial/usb_wwan.o
  CC [M]  /home/pi/files/drivers/./drivers/usb/serial/option.o
  CC [M]  /home/pi/files/drivers/./drivers/usb/serial/qcserial.o
  CC [M]  /home/pi/files/drivers/./drivers/net/usb/qmi_wwan.o
/home/pi/files/drivers/./drivers/net/usb/qmi_wwan.c: In function ‘qmimux_register_device’:
/home/pi/files/drivers/./drivers/net/usb/qmi_wwan.c:286:8: error: too few arguments to function ‘netdev_upper_dev_link’
  err = netdev_upper_dev_link(real_dev, new_dev);
In file included from /home/pi/files/drivers/./drivers/net/usb/qmi_wwan.c:15:0:
./include/linux/netdevice.h:4208:5: note: declared here
 int netdev_upper_dev_link(struct net_device *dev, struct net_device *upper_dev,
scripts/ recipe for target '/home/pi/files/drivers/./drivers/net/usb/qmi_wwan.o' failed
make[2]: *** [/home/pi/files/drivers/./drivers/net/usb/qmi_wwan.o] Error 1
Makefile:1524: recipe for target '_module_/home/pi/files/drivers' failed
make[1]: *** [_module_/home/pi/files/drivers] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.19.42-v7+'
Makefile:10: recipe for target 'modules' failed
make: *** [modules] Error 2

Even PPP failed as it “Could not determine remote IP address” after following the installation directions in Sixfab_RPi_3G-4G-LTE_Base_Shield/tutorials/tutorial3/

Can this be a problem with Twilio?

pi@raspberrypi:~ $ sudo pppd call gprs
pppd options in effect:
debug           # (from /etc/ppp/peers/gprs)
nodetach                # (from /etc/ppp/peers/gprs)
dump            # (from /etc/ppp/peers/gprs)
noauth          # (from /etc/ppp/peers/gprs)
remotename 3gppp                # (from /etc/ppp/peers/gprs)
/dev/ttyUSB3            # (from /etc/ppp/peers/gprs)
115200          # (from /etc/ppp/peers/gprs)
lock            # (from /etc/ppp/peers/gprs)
connect chat -s -v -f /etc/chatscripts/quectel-chat-connect -T              # (from /etc/ppp/peers/gprs)
disconnect chat -s -v -f /etc/chatscripts/quectel-chat-disconnect               # (from /etc/ppp/peers/gprs)
nocrtscts               # (from /etc/ppp/peers/gprs)
modem           # (from /etc/ppp/peers/gprs)
asyncmap 0              # (from /etc/ppp/options)
lcp-echo-failure 4              # (from /etc/ppp/options)
lcp-echo-interval 30            # (from /etc/ppp/options)
hide-password           # (from /etc/ppp/peers/gprs)
novj            # (from /etc/ppp/peers/gprs)
novjccomp               # (from /etc/ppp/peers/gprs)
ipcp-accept-local               # (from /etc/ppp/peers/gprs)
ipcp-accept-remote              # (from /etc/ppp/peers/gprs)
ipparam 3gppp           # (from /etc/ppp/peers/gprs)
noipdefault             # (from /etc/ppp/peers/gprs)
ipcp-max-failure 30             # (from /etc/ppp/peers/gprs)
defaultroute            # (from /etc/ppp/peers/gprs)
usepeerdns              # (from /etc/ppp/peers/gprs)
noccp           # (from /etc/ppp/peers/gprs)
noipx           # (from /etc/ppp/options)
abort on (BUSY)
abort on (NO CARRIER)
abort on (NO DIALTONE)
abort on (ERROR)
abort on (NO ANSWER)
timeout set to 30 seconds
send (AT^M)
expect (OK)
 -- got it
send (ATE0^M)
expect (OK)
 -- got it
send (ATI;+CSUB;+CSQ;+COPS?;+CGREG?;&D2^M)
expect (OK)
Revision: EC25AFAR05A04M4G^M
SubEdition: V06^M
+CSQ: 20,99^M
+COPS: 0,0,"Twilio",7^M
+CGREG: 0,1^M
 -- got it
send (AT+CGDCONT=1,"IP","",,0,0^M)
expect (OK)
 -- got it
send (ATD*99#^M)
expect (CONNECT)
 -- got it
Script chat -s -v -f /etc/chatscripts/quectel-chat-connect -T finished (pid 776), status = 0x0
Serial connection established.
using channel 1
Using interface ppp0
Connect: ppp0 <--> /dev/ttyUSB3
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x323b3594> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0xf <asyncmap 0x0> <auth chap MD5> <magic 0x7072f57e> <pcomp> <accomp>]
No auth is possible
sent [LCP ConfRej id=0xf <auth chap MD5>]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x323b3594> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x10 <asyncmap 0x0> <magic 0x7072f57e> <pcomp> <accomp>]
sent [LCP ConfAck id=0x10 <asyncmap 0x0> <magic 0x7072f57e> <pcomp> <accomp>]
sent [LCP EchoReq id=0x0 magic=0x323b3594]
sent [IPCP ConfReq id=0x1 <addr> <ms-dns1> <ms-dns2>]
rcvd [LCP DiscReq id=0x11 magic=0x7072f57e]
rcvd [LCP EchoRep id=0x0 magic=0x7072f57e 32 3b 35 94]
rcvd [IPCP ConfReq id=0xa]
sent [IPCP ConfNak id=0xa <addr>]
rcvd [IPCP ConfNak id=0x1 <addr> <ms-dns1> <ms-dns2>]
sent [IPCP ConfReq id=0x2 <addr> <ms-dns1> <ms-dns2>]
rcvd [IPCP ConfReq id=0xb]
sent [IPCP ConfAck id=0xb]
rcvd [IPCP ConfAck id=0x2 <addr> <ms-dns1> <ms-dns2>]
Could not determine remote IP address: defaulting to
local  IP address
remote IP address
primary   DNS address
secondary DNS address
Script /etc/ppp/ip-up started (pid 784)
Script /etc/ppp/ip-up finished (pid 784), status = 0x0

Please get the qmi_install script again and re-install. It has been modified for the latest kernel.

Regarding PPP, Please check the PPP installer tutorial.