R7800 performance

You need the QSDK 11 NSS firmware if you want to test my master branch codes. @Ansuel QSDK 10 branch has the feature for the NSS shaper and also the WiFi offload as well, so there's no difference between both repos as far as feature is concerned.

@moeller0 the 'tc' commands are different when invoking the NSS shapers. Need to target the NSS specific shapers when configuring SQM via Luci instead of the regular in-built shapers, and also take care of the parameters quirks for the NSS shapres. Also, no cake support in the NSS shapers.

1 Like

Mmmh, this sounds like what you need is a simple_nss.qos script, and probably no changes to the GUI.... Could you post the exact invocations?

The script below is used to configure both ingress and egress shapers:

# Shape ingress traffic to 500 Mbit with chained NSSFQ_CODEL
tc qdisc add dev nssifb root handle 1: nsstbl rate 500Mbit burst 1Mb
tc qdisc add dev nssifb parent 1: handle 10: nssfq_codel limit 10240 flows 1024 quantum 1514 target 5ms interval 100ms set_default

# Shape egress traffic to 200 Mbit with chained NSSFQ_CODEL
tc qdisc add dev eth0 root handle 1: nsstbl rate 200Mbit burst 1Mb
tc qdisc add dev eth0 parent 1: handle 10: nssfq_codel limit 10240 flows 1024 quantum 1514 target 5ms interval 100ms set_default

I forgot to add that there are quirks in which ethernet device to target for ingress shaping. The solution is also only for ethernet device only at the moment, but it should be enough for most real world use cases.

I have a simple read me doc here:

1 Like

perfect, I don't usually make any kernel changes, I don't have a level for that. where are the images to test? Thank you.

Do you need some special package or basic with Luci?

Only use:

luci spanish
OpenVPN
adblock
SQM (I see that it does not work with NSS)
wakeonlan

in addition to everything you need for a pppoe connection, firewall, vlan, etc.

thanks

So would it be as simple as adding those scripts to /etc/rc.local to get fq_codel?

and loading the standard baseline 3 NSS packages (What are all the additional packages needed, just nss-ifb?)

CONFIG_PACKAGE_kmod-qca-nss-drv=y
CONFIG_PACKAGE_kmod-qca-nss-gmac=y
CONFIG_PACKAGE_kmod-qca-nss-ecm-standard=y

If I remember correctly you need to also select the nss qdisk package

Please a summary of all this, I get lost :frowning:

Just need a build environment to compile openWRT images.

You can pull from the git that you want to try.

Example:

  1. create a directory (folder) for your build, run this command after you change in to that new directory using one of the git directories (quarky or Ansuel with the NSS changes):

git clone -b kernel5.4-nss-qsdk10.0 https://github.com/Ansuel/openwrt.git


  1. compile an OpenWRT image with the standard commands. During make menuconfig add the three base packages in my post above (plus qdisc and any other optional packages you desire, luci, etc)

./scripts/feeds update -a
./scripts/feeds install -a
make menuconfig
make

  1. now you have a sysupgrade .bin file in the new bin folder. :sunglasses:
2 Likes

shoudn't you source the firmware for the NSS cores somewhere as well?

1 Like

thanks but I don't get to that, possibly it makes the router unusable and I can't afford it. I will hope that something easier for mortals comes out.

The ansuel and quarky git repos already have everything you need to activate the NSS cores. :sunglasses: During the make menuconfig you need to select at a minimum these three packages to get NSS acceleration:


CONFIG_PACKAGE_kmod-qca-nss-drv=y
CONFIG_PACKAGE_kmod-qca-nss-gmac=y
CONFIG_PACKAGE_kmod-qca-nss-ecm-standard=y

I’ve been running a NSS core build in my main router:
image

These are the two main repos:

1 Like

You mean that's all that needs to be done? This is dead simple, and as moeller0 pointed out another script plus little mods if needed in the luci sqm or qos page should do. In fact once you put the script under /usr/lib/sqm it should show up in the drop down as queuing disciplines. The logic for it is not hardcoded. just look at the lua file.

Have you done tests with additonal prios/classes?

Currently messing with the NSS crypto engine, so SQM is lower in priority for me, since it works via scripts.

Have not tested the NSS prio shapers tho, but I guess it should work OK.

Is this planned for eventual submission to the official OpenWRT git repository, or going (e.g. for licensing or whatever other reasons) to stay as a perpetual fork?

One more question before I start working on this. You wrote:

printf eth1 > /sys/module/nss-ifb/parameter/nss_src_dev

You need to change the source interface first before bringing up the 'nssifb' interface. Changing it after the interface is up will have no effect. You need to bring down the interface and bring it back up to have the changes take effect.

Does this also work for pppoe, e.g.

printf pppoe-wan > /sys/module/nss_ifb/parameters/nss_dev_name

Has anyone tried nss with pppoe connection? There is an extra module shipped qca-nss-pppoe, does it have to be loaded for this use case?

Tested and works

It only work on eth0 and eth1, I.e physical interface. But since pppoe are working on top of eth0, it’ll get shaped when traffic gets encapsulated and sent via the eth interfaces.

As mentioned by @Ansuel, it works for pppoe as well.

Thanks, will try it. I have already created the qos script, that can be selected in sqm page, it takes the vars and runs. Need to test pppoe do some flent test and add rules if needed, then I can submit it.

2 Likes