QUECTEL PCIe mhi driver

I am using linux 6.X and i am need of quectel pcie mhi driver module and quectel-CM application.
Modem - RM520NGL
Could you please share?

Hi

I need a linux pcie quectel mhi driver and quectel-CM application

Hi,@Ranjith_Kumar_T_R
The driver and tool already send to you via email,pls check.

Hi Leon,

I didn’t receive the email.Could you please share the files to below email
ranjithtr2499@gmail.com

Hi

is quectel-CM can able to create a different apn with single interface?

if not is there any other solution for above issue?

Hello @leon.bao
Can you please also share the latest with me:

  • Quectel_Linux_PCIE_MHI_Driver
  • Quectel_Linux&Android_QMI_WWAN_Driver
  • Quectel QConnect manager

I cannot find it anywhere for download. We are using RM520 on Raspberry pi Compute Modul and use PCI-E for connection. Worked fine with Bullseye, but does not with Bookworm.

Hi,@olfeldma
I have sent them to you via email,pls check.

Hello @leon.bao ,
Thank you, I got them. Sadly I am still getting errors with the Version you sent. Can you help?

I am trying to cross compile the PCIE_MHI_Driver:
sudo make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- install

  CC [M]  /home/feldmo/pcie_mhi/core/mhi_init.o
/home/feldmo/pcie_mhi/core/mhi_init.c:2407:18: error: initialization of ‘int (*)(struct device *, const struct device_driver *)’ from incompatible pointer type ‘int (*)(struct device *, struct device_driver *)’ [-Werror=incompatible-pointer-types]
 2407 |         .match = mhi_match,
      |       

The last time i did this with version 1.3.5 i got multiple errors also in other files, because they did not fit to the latest raspberry pi os version we are using (bookworm linux-headers-6.12.25+rpt-rpi-v8)

Hi,@olfeldma
According to the error message, you can try to change the parameter <struct device_driver *> to <const struct device_driver *> in the mhi_init.c code as stated in the message.

Hi @leon.bao ,
I have fixed both builds to run on a raspberry pi (Bookworm 6.12.25+rpt-rpi-v8)

Perhaps this can help someone else with the same issue.

Quectel_fixed_QMI_WWAN.zip (96.9 KB)
Quectel_fixed_PCI_MHI.zip (524.5 KB)

Hi,@olfeldma
Thank you very much for your help.

Hello, how about the Qconnectmanager? I tried to buid but failed.Here is log:
···
make
rm -rf .o libmnl/.o quectel-CM quectel-qmi-proxy quectel-mbim-proxy quectel-atc-proxy
gcc -Wall -Wextra -Werror -O1 quectel-qmi-proxy.c -o quectel-qmi-proxy -lpthread -ldl -lrt
gcc -Wall -Wextra -Werror -O1 quectel-mbim-proxy.c -o quectel-mbim-proxy -lpthread -ldl -lrt
gcc -Wall -Wextra -Werror -O1 quectel-atc-proxy.c atchannel.c at_tok.c util.c -o quectel-atc-proxy -lpthread -ldl -lrt
quectel-atc-proxy.c: In function ‘atc_proxy_init’:
quectel-atc-proxy.c:261:13: error: ignoring return value of ‘asprintf’ declared with attribute ‘warn_unused_result’ [-Werror=unused-result]
261 | asprintf(&cmd, “AT+QCFG="NAT",%d”, new_nat);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [Makefile:43:atc-proxy] ERROR 1
···
Any latest driver or code?

Hi,@Anonymous01
I have sent the lastest one to you via email,pls check.

QConnectManager returns same errors while built/made code on Ubuntu 24.04 lts with kernel ver 6.11.

No help. Same errors and can not build it.

Hi,@Anonymous01
According to the error message, it is because the"asprintf"function requires return value checking. You can try adding return value checking and then compile again. Make the following modifications in the "quectel-atc-proxy.c" file:

int ret = asprintf(&cmd, “AT+QCFG="NAT",%d”, new_nat);
if (ret < 0) {
perror(“asprintf failed”);
exit(EXIT_FAILURE);
}

From which lines to insert this code?

Hi,@Anonymous01
You can search for the keyword “asprintf” to locate the relevant code sections.

We’re trying to install on RPI5 using Ubuntu 24 and get the following error after entering: “dmesg | grep -i mhi”

failed to prepare MHI controller
error -12

which suggest were missing firmware files like: * mhi_amss.mbn
mhi_boot.mbn
mhi_core.mbn
mhi_tz.mbn
mhi_sbl1.mbn

Any ideas?