Qualcommax NSS Build

Whenever you have build errors while doing parallel builds always look for the string

] Error 1

That will point to where in the sequence the failure occurred and the cause.

You can also run make with -j1 which will force it to build in serial to help trace the issue.

I'm probably doing something wrong as well. Excuse my ignorance, I just run the command again with the option you mentioned (make -j1$(nproc) V=s) and I got this error now:

checking whether mkfifoat rejects trailing slashes... yes
checking whether mknod can create fifo without root privileges... configure: error: in `/opt/openwrt/openwrt-ipq/build_dir/host/tar-1.35':
configure: error: you should not run configure as root (set FORCE_UNSAFE_CONFIGURE=1 in environment to bypass this check)
See `config.log' for more details
make[3]: *** [Makefile:36: /opt/openwrt/openwrt-ipq/build_dir/host/tar-1.35/.configured] Error 1
make[3]: Leaving directory '/opt/openwrt/openwrt-ipq/tools/tar'
time: tools/tar/compile#9.25#5.32#17.31
    ERROR: tools/tar failed to build.
make[2]: *** [tools/Makefile:231: tools/tar/compile] Error 1
make[2]: Leaving directory '/opt/openwrt/openwrt-ipq'
make[1]: *** [tools/Makefile:227: /opt/openwrt/openwrt-ipq/staging_dir/host/stamp/.tools_compile_nyyynyynnnyyyynynyyyyyyynyyynynyynnynnyyyyyynyyyyyyyyyyynynnyyyyynyyy] Error 2
make[1]: Leaving directory '/opt/openwrt/openwrt-ipq'
make: *** [/opt/openwrt/openwrt-ipq/include/toplevel.mk:248: world] Error 2

I just want to learn how to build my own, so I'm very new to this.

edit: nevermind, I just saw where the logs are saved (config.log). Also I switched to a regular user and not using root.

Don't build as root or any privileged user (via sudo commands).

It's actually supposed to be:

make -j1 V=s

The tool nproc is a shortcut to finding the number of processing cores on your computer for when running parallel builds...
image

Doing a 1 in front of $(nproc) potentially adds 10 to 100 more threads.
image

Hello @qosmio ,

The point is that I'm using the router as a dummy AP, so I'm not using NSS, right? Then the vlan filtering should work fine, right?

Best regards,
Paulo

Hello @AgustinLorenzo ,

This fix will be included in the next build to test with VLAN filtering?

Best regards,
Paulo

Hi @paulomp

Of course it is part of the upstream, but I don't think it will solve anything since we don't use DSA.

@qosmio, can you confirm if this will affect anything?

Regards, Agustin

Hi all. I have updated with the latest commit / kernel from @qosmio .

I would like to ask, when doing speedtest I can see its now eating my processor compared from previous release that its almost idle?

Is NSS supposed to offload traffic and not eat cpu resource when doing speedtest?

Using 11.x nss
6.6.57 kernel
Arcadyan AW1000

It wont really help in our use case.

Hello, I am building fresh using 6.6.57 kernel with 11.4 NSS
installed LUCI and quectel CM alone.
modem immediately restarts after quectel cm dials

[   33.160937] NSS core 0 signal COREDUMP COMPLETE 4000
[   33.165413] ffffffc079050000: Starting NSS-FW logbuffer dump for core 0
[   33.170370] Kernel panic - not syncing: NSS FW coredump: bringing system down
[   33.176702] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G           O       6.6.57                                                                              #0
[   33.183992] Hardware name: Arcadyan AW1000 (DT)
[   33.191452] Call trace:
[   33.195702]  dump_backtrace+0xa0/0xe0
[   33.198135]  show_stack+0x18/0x24
[   33.201952]  dump_stack_lvl+0x48/0x60
[   33.205251]  dump_stack+0x18/0x24
[   33.208897]  panic+0x2dc/0x330
[   33.212195]  nss_fw_coredump_notify+0x1e4/0x3c4 [qca_nss_drv]
[   33.215152]  nss_core_handle_napi_emergency+0x38/0x4c [qca_nss_drv]

I would check with @XT-Martinez:

Most of my work on NSS offload for WWAN was in the initial port. I don't have a cellular based router so I am unable to personally test for these type of devices.

My guess is it's something to do with the recent merge done around end of September. That's when I started seeing a lot these posts regarding kernel panics on these devices.

date commit desc
2024-10-08 0c05fe6 Update quectel.sh (#36)
2024-09-24 47cc754 Update quectel.sh (#33)
2024-08-06 27c9b64 Add config for 4G cell ID locking
2024-08-05 6ac90d5 Make IP Multiplexing optional
2024-07-18 28cc54f Add config for PDN index, cleanup modem boot delay
2024-07-15 1a6ba49 Update quectel proto script to support dual-stack IP via QMAP multiplexing
2024-07-15 01fe8de Add enough delay to wait for modem to boot

Most of the changes are to wwan/app/quectel-cm/files/quectel.sh so don't require a full rebuild if you want to quickly test it. You can manually switch out that file starting from the first commit and work your way up to see when it fails.

git -C feeds/nss_packages checkout 0c0f106 -- wwan/app/quectel-cm/files/quectel.sh
make package/cleanup package/quectel-cm/{clean,compile} package/install target/install V=s -j$(nproc)

I need some help. I've been breaking my brain (or skillset) trying to get vlan's working on a Netgear WAX218. It has a single lan poe port. Using DSA it works on the regular builds. Using @AgustinLorenzo builds it doesn't. A client connects but doesn't get an IP from the central router (also OpenWRT on x86-64).

I've followed the example given by @qosmio on his github.

Network config currently is:


config interface 'loopback'
	option device 'lo'
	option proto 'static'
	option ipaddr '127.0.0.1'
	option netmask '255.0.0.0'

config globals 'globals'
	option ula_prefix 'xxxxxxxxxxxx::/48'
	option packet_steering '0'

config device
	option name 'br-lan'
	option type 'bridge'
	list ports 'lan'
	option igmp_snooping '1'
	option ipv6 '0'

config interface 'lan'
	option device 'br-lan'
	option force_link '0'
	option proto 'dhcp'

config interface 'wlan'
	option proto 'none'
	option device 'br-wlan'

config interface 'iot'
	option proto 'none'
	option device 'br-iot'

config device
	option type '8021q'
	option ifname 'lan'
	option vid '2'
	option name 'lan.2'

config device
	option type '8021q'
	option ifname 'lan'
	option vid '10'
	option name 'lan.10'

config device
	option type 'bridge'
	option name 'br-wlan'
	list ports 'lan.10'
	option igmp_snooping '1'

config device
	option type 'bridge'
	option name 'br-iot'
	list ports 'lan.2'
	option igmp_snooping '1'

vlan 1 is the 'management' vlan and is untagged. Any help is appreciated.

Hello, just checking if anyone using NSS with the latest kernel, are you still seeing process being offloaded? When doing speedtest I can see the graph from htop spiking to 80 % for CPU 3. Default setup, no VLAN, just luci, quectel,3ginfo,modemband and htop installed.

Kernel 6.6.57
NSS 11.4

I ensured that NSS / RMNET drivers are checked. HW / SW offloading us unchechecked.

You should mention the device, as your use case is specific to cellular offloading. I added a script while back, just paste your output from nss_diag

thank you for the response @qosmio
below is my nss diag

root@OpenWrt:~# nss_diag
     MODEL: Arcadyan AW1000
   OPENWRT: unknown
IPQ BRANCH: N/A
IPQ COMMIT: N/A
  IPQ DATE: N/A
    NSS FW: NSS.HK.11.4.0.5-6-R
  MAC80211: v6.11.2-0-g7aa21fec187b
 ATH11K FW: WLAN.HK.2.9.0.1-02146-QCAHKSWPL_SILICONZ-1
  GRO FRAG: br-lan      : off
            erspan0     : off
            gre0        : off
            gretap0     : off
            lan1        : off
            lan2        : off
            lan3        : off
            lan4        : off
            phy0-ap0    : off
            phy1-ap0    : off
            wan         : off
            wwan0       : off
            wwan0_1     : off

  NSS PKGS: kmod-qca-nss-dp - 6.6.57.2024.04.16~5bf8b91e-r1
            kmod-qca-nss-drv - 6.6.57.11.4.0.5.2021.09.13~53e5863-r15
            kmod-qca-nss-drv-bridge-mgr - 6.6.57.11.4.0.5.2021.08.17~c4049d1-r7
            kmod-qca-nss-drv-vlan-mgr - 6.6.57.11.4.0.5.2021.08.17~c4049d1-r7
            kmod-qca-nss-ecm - 6.6.57.12.5.5.2024.09.02~bd5057b-r3
            nss-firmware-default - 2024.08.04~794fe373-r1
            nss-firmware-ipq8074 - 2024.08.04~794fe373-r1
root@OpenWrt:~#

Yes, I'm fully offloaded. Zero CPU - LAN and WiFi 1Gbps.

nss_diag
root@QNAP:~# nss_diag
     MODEL: QNAP 301w
   OPENWRT: r28017-18df6f3502
IPQ BRANCH: qualcommax-6.x-nss-wifi
IPQ COMMIT: 18df6f3502
  IPQ DATE: 2024-10-21
    NSS FW: NSS.FW.12.2-161-HK.R
  MAC80211: v6.11.2-0-g7aa21fec187b
 ATH11K FW: WLAN.HK.2.9.0.1-02146-QCAHKSWPL_SILICONZ-1
  GRO FRAG: 10g-1       : off
            10g-2       : off
            br-lan      : off
            br-vlan     : off
            erspan0     : off
            gre0        : off
            gretap0     : off
            lan1        : off
            lan2        : off
            lan3        : off
            lan4        : off
            phy0-ap0    : off
            phy0-ap1    : off
            phy1-ap0    : off
            wg0         : off
            wg1         : off
            wg2         : off

  NSS PKGS: kmod-qca-nss-dp - 6.6.57.2024.04.16~5bf8b91e-r1
            kmod-qca-nss-drv - 6.6.57.12.5.2024.04.06~53a0dc1-r15
            kmod-qca-nss-drv-bridge-mgr - 6.6.57.12.5.2024.06.12~1bcef16-r7
            kmod-qca-nss-drv-igs - 6.6.57.12.5.2024.06.12~1bcef16-r7
            kmod-qca-nss-drv-qdisc - 6.6.57.12.5.2024.06.12~1bcef16-r7
            kmod-qca-nss-drv-vlan-mgr - 6.6.57.12.5.2024.06.12~1bcef16-r7
            kmod-qca-nss-ecm - 6.6.57.12.5.5.2024.09.02~bd5057b-r3
            nss-firmware-default - 2024.08.04~794fe373-r1
            nss-firmware-ipq8074 - 2024.08.04~794fe373-r1

Unfortunately I still cannot find a solution to the WireGuard speed drop to 2-3Mbps.

1 Like

How are you building this image? This shouldn't be like this if using my repository as the base. Did you fork it?

I downloaded https://github.com/qosmio/openwrt-ipq
Extracted it then
scripts/feeds update -a
Scripts/feeds install -a
Make menu config
Make -j5

Should I use git clone instead?

I suggest you use example NSS .configs

2 Likes

I push changes fairly regularly, you should always build from git version. It also lets me know which commit you're on to better track bugs.

If size is a concern you can do a shallow initial clone.

git clone https://github.com/qosmio/openwrt-ipq --depth 1

Understood and appreciate your feedback. Im building based o. The instructions above. Will test after.