I just installed OpenWRT on a new x86 machine, and I am trying to install some drivers I got from Quectel for the module EM160R-GL to work in PCIe mode.
I installed make, but when I run the command make or make install I get:
root@OpenWrt:~/pcie# make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/4.14.167/build M=/root/pcie clean
make[1]: *** /lib/modules/4.14.167/build: No such file or directory. Stop.
make: *** [Makefile:29: clean] Error 2
I am not sure why this isn't working, am I missing some package I should have installed?
Actually, it doesn't say anything about the version, I will try older versions, thanks.
Unfourtently, all the topics discuss how to get it to work in USB, which I was already able to do quite easily, I am trying to get it to work in PCIe mode, for which I did not find even a single piece of information online.
Not in PCIe mode, it works in USB mode, and yes I am 100% sure, it is listed in lsusb, it brings up an interface, and I can ping the internet.
Thanks, I am almost sure that too is the USB version, not the PCIe version, but I will give it a try!
I can find any x86 images on their website, can you please point me in the right direction?
Those instructions assume you have built a custom image and have /lib/modules/kernelversionhere/build pointing to the kernel's build directory/headers. OpenWRT is meant for resource-constrained embedded devices, so it doesn't ship with the kernel's sources or headers.
If you want it compiled, you'll need to build a complete custom image.
That is amazing news to hear that it works for you on em12, they are very similar modems, so I have some hope now.
I installed rooter, and the modem is detected in USB mode by default, but when I issue AT+QCFG="data_interface",1,0 to turn the modem into PCIe mode, I get an unknown device: 06:00.0 Unassigned class [ff00]: Device 1eac:1002 (rev ff).
Did you take any special steps or did it work out of the box for you?
I would not fight with any code from Quectel (or any other vendor) unless they provide
working code, and
support
That's the only valid reasons to ever consider using out-of-tree code IMHO. If you don't get both, then it's just not worth the effort.
The PCIe EM160R-GL is supported in Linux mainline since commit ac4bf60bbaa0 ("bus: mhi: pci_generic: Introduce quectel EM1XXGR-L support"). This commit is in v5.13 and later. The drivers are also available as a package in OpenWrt master (for targets with v5.15 support). You don't need to use any Quectel code.
If you need this on a target where v5.15 isn't yet available, then you have two options which both seems a lot easier than getting some quectel driver to build on a 5 year old kernel:
Hmm, that is weird, since I did try it on Ubuntu 21.10 which I believe is v5.13 (maybe v5.14) and had the exact same issue.
I am sorry, this may be a noob question, do you mean I need to manually install the latest OpenWrt version and then upgrade the kernel to v5.15 and then install the package using opkg?