This is meant to ease debugging when asking for support. Just run the
command "nss_diag" and include in your issues/forum posts.
Example of output
```
MODEL: Linksys MX5300
OPENWRT: r27645+154-f9a0485c99
IPQ BRANCH: qualcommax-6.x-nss-mx4300-6.11
IPQ COMMIT: 04c2d8a2db
IPQ DATE: 2024-10-04
NSS FW: NSS.HK.11.4.0.5-6-R
MAC80211: v6.11.2-0-g7aa21fec187b
ATH11K FW: WLAN.HK.2.9.0.1-01977-QCAHKSWPL_SILICONZ-1
GRO FRAG: wan : off
br-lan : off
lan1 : off
lan2 : off
lan3 : off
lan4 : off
phy0-mesh0 : off
phy1-ap0 : off
phy2-ap0 : off
NSS PKGS: kmod-qca-nss-cfi-cryptoapi - 6.6.54.12.5.2022.12.15~5cd07ce-r3
kmod-qca-nss-crypto - 6.6.54.12.5.2022.12.15~3c5a574-r3
kmod-qca-nss-dp - 6.6.54.2024.04.16~5bf8b91e-r1
kmod-qca-nss-drv - 6.6.54.11.4.0.5.2021.09.13~53e5863-r14
kmod-qca-nss-drv-bridge-mgr - 6.6.54.11.4.0.5.2021.08.17~c4049d1-r7
kmod-qca-nss-drv-igs - 6.6.54.11.4.0.5.2021.08.17~c4049d1-r7
kmod-qca-nss-drv-qdisc - 6.6.54.11.4.0.5.2021.08.17~c4049d1-r7
kmod-qca-nss-drv-vlan-mgr - 6.6.54.11.4.0.5.2021.08.17~c4049d1-r7
kmod-qca-nss-drv-wifi-meshmgr - 6.6.54.11.4.0.5.2021.08.17~c4049d1-r7
kmod-qca-nss-ecm - 6.6.54.12.5.5.2024.09.02~bd5057b-r2
nss-eip-firmware - 2.5.7-r3
nss-firmware-default - 2024.08.04~794fe373-r1
nss-firmware-ipq8074 - 2024.08.04~794fe373-r1
```
Signed-off-by: Sean Khan <datapronix@protonmail.com>
(cherry picked from commit a58914b4f788f6b5ee70ddad0a1f5c4e464a5629)
* Refactor and clean up script and add more helpful docs.
* If a device's MAC doesn't match or isn't specified the following will
be configured:
1.) lan network will use DHCP ("lan_proto=dhcp") to retrieve an IP
2.) device name will be "mx4300-xxxx", where "xxxx" represents the
last 4 characters of the device MAC address found on the bottom of
sticker.
* When in bridge mode, devices can be setup to use static or dhcp for their lan interface.
This is specified with option "lan_proto=dhcp" under each devices's
config, or if no suffix is specified, it is assumed the IP needs to be
optained.
* Add fallback mgmt IP address 10.1.1.1 that can be used in case mesh
fails to come up and hardwire connection is required. Make sure to set
a static IP for your computer in the 10.1.1.x subnet in order to
connect.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Included starter config seed NSS offloading for MX4300. Although it can
be used by any compatible ipq807x NSS setup.
There is also an example 'uci-defaults' script that you can use to build
a single image for multiple nodes.
Although the script includes options to set low/high band for mesh backhaul.
Only the high-band works for offloading.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Generic ndo_get_stats64 was removed in kernel > 6.9. This ends up
breaking interface stats on NSS builds.
```
phy0-ap0 Link encap:Ethernet HWaddr
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:841 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
phy1-ap0 Link encap:Ethernet HWaddr
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
```
Until a better workaround is implemented revert the following patch.
```
commit c018411d355518a0b2a304d7543564cdd1b808b6
Author: Breno Leitao <leitao@debian.org>
AuthorDate: Fri Jun 7 03:20:44 2024 -0700
Commit: Johannes Berg <johannes.berg@intel.com>
CommitDate: Wed Jun 12 13:04:24 2024 +0200
wifi: mac80211: Remove generic .ndo_get_stats64
Commit 3e2f544dd8a33 ("net: get stats64 if device if driver is
configured") moved the callback to dev_get_tstats64() to net core, so,
unless the driver is doing some custom stats collection, it does not
need to set .ndo_get_stats64.
Since this driver is now relying in NETDEV_PCPU_STAT_TSTATS, then, it
doesn't need to set the dev_get_tstats64() generic .ndo_get_stats64
function pointer.
In this driver specifically, .ndo_get_stats64 basically points to
dev_fetch_sw_netstats(). Now it will point to dev_get_tstats64(), which
calls netdev_stats_to_stats64() and dev_fetch_sw_netstats().
netdev_stats_to_stats64() seems irrelevant for this driver.
```
Signed-off-by: Sean Khan <datapronix@protonmail.com>
This patch replaces the problematic NAWDS stateless mode with standard
WDS in the ath11k driver. NAWDS has shown incompatibility with WDS AP
and STA modes in ath11k, leading to issues like MAC address
duplication and unstable connections. By switching to standard WDS,
this patch aims to resolve these issues.
It also enables WDS backhaul in NSS for better handling of backhaul links.
Testing is still ongoing, but early results indicate improved
stability and fewer connection problems in affected environments
Authored-by: Sebastian Gottschall <s.gottschall@dd-wrt.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Currently we are dereferencing dev pointer without a NULL
check.
Fix this issue by adding a NULL check.
Patch-dependency: none
Patch-work: none
Fixes: 4b7afb52c8e2 (mac80211: reorganize code to remove a forward declaration)
Note: ath.git commit id is mentioned in the Fixes tag
Signed-off-by: Monika Korada <quic_koramoni@quicinc.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
When a station idles for a long time, hostapd will try to send
a QoS Null frame to the station as "poll". NL80211_CMD_PROBE_CLIENT
is used for this purpose.
And the skb will be added to ack_status_frame - waiting for a
completion via ieee80211_report_ack_skb().
But when the peer was already removed before the tx_complete arrives,
the peer will be missing. And when using dev_kfree_skb_any (instead
of going through mac80211), the entry will stay inside
ack_status_frames thus not clean up related information in its
internal data structures. This IDR will therefore run full after
8K request were generated for such clients.
At this point, the access point <M-[>48;55;187;1760;2992will then just stall and not allow
any new clients because idr_alloc() for ack_status_frame will fail.
ieee80211_free_txskb() on the other hand will (when required) call
ieee80211_report_ack_skb() and make sure that (when required) remove
the entry from the ack_status_frame and clean up related
information in its internal data structures.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
This original patch: 237-006-ath11k-Allow-fast-rx-by-bypassing-stats-update.patch
was split into two patches:
237-001-ath11k-Allow-fast-rx-by-bypassing-stats-update.patch
237-006-ath11k-Allow-fast-rx-by-bypassing-stats-update.patch
Merge them back together to avoid confusion
Signed-off-by: Sean Khan <datapronix@protonmail.com>