IPQ806x NSS Drivers

You mean as in this goes too deep as a starting point?

I know I have a LOT to learn and I'm fine with that; I see this as a long term project. I may not understand everything fully what I've read so far in this thread (now), but I've already picked up several useful bits. Usually when I've learned more, pieces that I didn't (fully) understand before, will fall into place later.

I have several objectives. One is getting a more secure router by amongst other things run a (more) recent and still supported kernel (instead of 3.4.103). Another is showing the power of Open Source and OpenWrt seems like the best project to do that with (when it comes to routers). My assumption is that I'd also need IPQ806x NSS drivers to get good performance, which I of course want (if possible).
If I can help get my router into a supported state with OpenWrt, that would be really cool :slight_smile:

1 Like

After you get your device working with OpenWRT feel free to evaluate one of my repos (or clone them) if you want to try NSS for your device.

1 Like

Not really. It doesn’t contain information on how to get an ipq806x router running OpenWrt. It assumes OpenWrt is already running properly before attempting NSS. So applying the knowledge in this thread on a router without OpenWrt running will likely be confusing.

1 Like

Hi guys,

I've been following this even though I'm from a different party called IPQ807x, and I have a doubt and maybe you guys can enlighten me.
Do all these offloading packages have support for nftables?
Since openwrt is migrating away from iptables for good, is there a way to make this work with nftables? I've seen most of the dependencies have to do with conntrack which is the same for iptables and nftables, but it also has some dependencies on iptables-mox-extra, that should be replaceable with nftables right?

Also, for the TC offloading, could there be a way in the future of adding cake offloading? Is this TC offloading currently transparent? Or is there a need to use a special nss tool?

Thanks!

@ACwifidude
got some update or what is the best / most stable release for now?

thanks!

I updated the 21.02, 22.03, and master builds on April 15th. If you are looking for a recent stable build I’d load the 22.03 build. :sunglasses:

1 Like

thanks but is there anything specific behind the fact that still version 21x and 22x are kept?

I'm still on 21.02.1 with my R7800 as I don't want to run into this 5GHz wifi stalling issue that was likely introduced in 21.02.2.

I don't get the sense it was solved in 21.02.3 either. Or am I wrong and has it been fixed now? Should I wait for 22.03?

I realize it's quite an old post, but I didn't see someone reporting who was running OEM firmware ... and I am. It's an Asus BRT-AC828 (unsupported by OpenWrt (currently)) running asuswrt (although that isn't relevant afaict).

Firmware version (from IPQ806x NSS Drivers - #2603 by diederik):

strings retail_router0.bin
Version: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0
TIDQ_TTL_EXPIRE_CNT_7 = 0
TIDQ_DEQUEUE_REQ_CNT_0 = 0
TIDQ_DEQUEUE_REQ_CNT_1 = 0
TIDQ_DEQUEUE_REQ_CNT_2 = 0
TIDQ_DEQUEUE_REQ_CNT_3 = 0
TIDQ_DEQUEUE_REQ_CNT_4 = 0
TIDQ_DEQUEUE_REQ_CNT_5 = 0
TIDQ_DEQUEUE_REQ_CNT_6 = 0
TIDQ_DEQUEUE_REQ_CNT_7 = 0
TOTAL_TIDQ_DEPTH = 0
RX_HTT_FETCH_CNT = 0
TOTAL_TIDQ_BYPASS_CNT = 0
GLOBAL_Q_FULL_CNT = 0
TIDQ_FULL_CNT = 0


wifi stats end

So that's the same as @ACwifidude's output.
Some other data:

root@BRT-AC828:/sys/kernel/debug# uptime
 16:38:33 up 60 days,  2:19,  load average: 3.16, 3.08, 3.06
root@BRT-AC828:/sys/kernel/debug# uname -a
Linux BRT-AC828 3.4.103 #1 SMP PREEMPT Wed Apr 8 11:19:22 CST 2020 armv7l ASUSWRT

HTH

1 Like

Regarding the spinlock error when running br-lan in promisc mode.
I checked the boot log from the OEM firmware, it seems like the bridge (actually all interfaces) is set to promisc mode. So it's a default setting in OEM FW. But for some reason it doesn't work in the OpenWrt NSS implementation/port.

Well, the NSS ECM driver used in the stock firmware is very old, I think QSDK 6.x. Also, IIRC, the Linux kernel is v3.x in the stock firmware.

The drivers we're using for 21.02/master is at least QSDK 10.x on Linux v.5.4.x. I wouldn't be surprised if there're bugs introduced since then.

1 Like

I have try your latest 22.03 build but encounter random disconnect from router. Is it nss driver currently unstable on kernel 5.10?

ath10 devices are working out a bug with wifi. Hopefully will have a fix here shortly. Thankfully it is not NSS related.

hi, @ACwifidude
is there currently stable / wifi bug free image for r7800? if so which image for ath10k or ath10k-ct?

thanks

The latest master build has the bug fixes in it. Several users are using ath10k, I’m using ath10k-ct. both seem to be working well.

2 Likes

@ACwifidude thanks, do u have specific purpose behind why you run 10k-ct?

also odd question but again i cant find yours the images in that thread.

All my clients (apple devices + IoT) all are happy with ath10k-ct. Speeds are good, never have seen any reason to swap (for my setup). :sunglasses:

@acwifidude what do u mean by IoT like what iot devices.
do u mind to share link to images? appreciate

Everything that can be wired - I have it wired. Ex: Linux box, access points, etc

IoT = Amazon Smart thermostats, Alexa speakers, cameras, and other similar devices that only require an internet connection (these connect to the slower 2.4ghz only SSID). I went with mostly Amazon smart devices to stay under one smart device umbrella.

My iPhone, iPad, and other similar “fast” devices use the 5ghz only SSID. I have Apple devices to keep the family happy.

I keep my settings simple and run all the optimizations I have in post #2 of my build thread. I’ve found ath10k-ct has worked just fine with no significant disconnects or issues.

1 Like

Are you still working on this?
I would like to work on this since now I have other device as my main router :smiley: