fixes: ath11k: fix peer addition/deletion error on sta band migration: d673cb6fe6c03b2be157cc6c5db40481828d282d
the fix for sta band migration raises a new bug which causes the wifi
firmware to crash if you switch between 2 bssid's on the same band. this is
usually caused since the firmware observes 2 stations with the same
bss
Signed-off-by: Sebastian Gottschall <s.gottschall@dd-wrt.com>
Update 999-900-bss-transition-handling.patch
Signed-off-by: qosmio <datapronix@protonmail.com>
Every 100 milliseconds, the station sends an "association request" and
the AP adds the peer and the AP responds to the station with an
"association response".
But "association response" takes time to reach the station. Because of
this, the station sends another "association request" to the AP.
In the second associate request, the AP removes the peer and re-adds
the station. Meanwhile, "association response" is reached to station
and station sends "QoS NULL" frame to AP.
The moment the station sends a QoS NULL frame to the ap, the peer on
the AP is deleted and the AP sends a de-authentication to the station.
To fix this issue, increased the assoc timeout period from 100 milli-
seconds to 500 milli seconds.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
There is an issue when enabling thermal support on newer ath11k firmware.
TX/RX rates are being limited, often times 50% of client's HE
capabilities.
The issue stems from a mismatch in WMI API structure. The range to
throttle is currently "-100°C" to "150°C", this essentially means
"always" throttle.
Integrate patch from dd-wrt which adds missing WMI structures and
proper thermal ranges for IPQ5018, IPQ807x, and QCN9000.
Patch-by: Sebastian Gottschall <s.gottschall@dd-wrt.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
There was logic that was initially included in the coconut branch of
QSDK for older mac80211 NSS implementation. It was brought over to
address an issue with ath10k where during heavy traffic, AP would trigger
`failed to increase tx pending count: -16, dropping`.
The issue was actually caused by `skb_recyler` malforming some packets.
Disabling `skb_recyler` fixed the error, and therefore the logic
regarding `skb_queue_len(&local->pending[q]) >= 1000` can be reverted to
match what is currently upstream with QSDK.
Alsi refreshed remaning patches after rebase.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
There are instances where `skbuff_recycle` messes up skb headers causing
various issues in network related activities. This was initially meant
to resolve issues with memory usage issues on 6.1.
Introduce a proc option to enable or disable skbuff_recycle. The default
is to have it enabled. Users on 512M platforms should test if memory
leaks still occur with this option disabled.
echo 0 > /proc/net/skb_recycler/skb_recycler_enable
echo 1 > /proc/net/skb_recycler/skb_recycler_enable
NOTE: There is a new script in `qca-nss-drv` that will automatically
manage this as an UCI configurable option.
commit 217a4fa43ba2ad0a02e8080dfde11ad23534aa8c (HEAD -> NSS-12.5-K6.x)
Author: Sean Khan <datapronix@protonmail.com>
AuthorDate: Sat Jul 13 18:43:52 2024 -0400
Commit: Sean Khan <datapronix@protonmail.com>
CommitDate: Sat Jul 13 18:43:52 2024 -0400
nss-drv: add skb_recycler init script
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Rather mess with target 'config-*' files, introduce a custom menu item
that consolidates all IPQ related kernel settings in one menu.
Most of these can be left as default since the options are derived from the
initial NSS fork for 'config-6.6'.
Options include:
1) enable or disable building `skbuff_recycle`
2) enable or disable preemption
3) select IPQ memory profile
Signed-off-by: Sean Khan <datapronix@protonmail.com>
New:
* Add UCI option to /etc/config/pbuf
1. `stats_disable` - Allows disabling extended stats
collection. (Default: '1')
2. `scaling_governor` - Allow specifying CPU governor.
(Default: disabled )
Choices depend on what your system is compiled with. Can be found
using:
```sh
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
ondemand performance schedutil
```
Changes:
* Rather than hardcode every device model's memory profile. Simply read the
memory available from `/proc/meminfo`.
* Scaling governor is no longer forced as `performance`. It is now user
configurable.
* Hash bitmap is now calculated from number of CPUs rather than hardcoded to `15`
* Limit `n2h_queue_limit_core` to `256`. This was set to `2048` which is
too high when NSS wifi is also enabled.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Some features are not available in NSS firmware 11.4.0.5
* `NSS_WIFI_VDEV_EXT_DATA_PKT_TYPE_4ADDR`
This was introduced in `NHSS.QSDK.11.5`. To avoid unexpected issues,
disable the case check for `NSS_WIFI_VDEV_EXT_DATA_PKT_TYPE_4ADDR` if
`CONFIG_NSS_FIRMWARE_VERSION_11_4` is selected.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
ath11k_nss: rename '*.patch.patch' to '.patch'
Signed-off-by: Sean Khan <datapronix@protonmail.com>
This patch handles the updating of MU-EDCA parameters indicated by
driver. Driver requests to update the parameters and Parameter Set
Update Count in beacon frames. This patch addresses only AP mode.
Three actions are taken to successfully update MU-EDCA parameters
in beacon:
(1) Update MU-EDCA parameters stored in hostapd
The following Access Categories (AC) are updated:
VO: Voice
VI: Video
BE: Best Effort
BK: Background
(2) Increment Parameter Set Update Count
(3) Update beacon with new parameters
There aren't any options to configure, hostapd simply updates MU-EDCA
published by ath11k driver.
To verify params are getting updated, set log_level to '1' and check
logger
i.e. `uci set wireless.radio0.log_level=1`
```
Sat Jul 6 15:36:10 2024 daemon.debug hostapd: phy0-ap0: IEEE 802.11 MU-EDCA: Updated MU-EDCA parameters for AC 0: BE: 3, BK: 7, VI: 2, VO: 2
Sat Jul 6 15:36:10 2024 daemon.debug hostapd: phy0-ap0: IEEE 802.11 MU-EDCA: Updated MU-EDCA parameters for AC 1: BE: 164, BK: 164, VI: 67, VO: 50
Sat Jul 6 15:36:10 2024 daemon.debug hostapd: phy0-ap0: IEEE 802.11 MU-EDCA: Updated MU-EDCA parameters for AC 2: BE: 255, BK: 2, VI: 255, VO: 255
```
Requires the following patches applied to 'ath11k/subsys'
commit ce7f1ad354869d85abdf8e8ed8d36599e057ba5d
Author: Sean Khan <datapronix@protonmail.com>
AuthorDate: Tue Feb 27 00:45:32 2024 -0500
Commit: Sean Khan <datapronix@protonmail.com>
CommitDate: Sat Jul 6 15:19:26 2024 -0400
ath11k_nss: FW Initiated Dynamic MU-EDCA
package/kernel/mac80211/patches/nss/ath11k/203-mac80211-ath11k-fw-dynamic-muedca.patch
package/kernel/mac80211/patches/nss/subsys/203-mac80211-ath11k-fw-dynamic-muedca.patch
Signed-off-by: Sean Khan <datapronix@protonmail.com>
commit 072327212c033baf96365a5045673c5981eb0bdf (HEAD -> next, origin/next)
Author: John Crispin <john@phrozen.org>
AuthorDate: Fri Jul 5 15:42:24 2024 +0200
Commit: John Crispin <john@phrozen.org>
CommitDate: Fri Jul 5 15:42:40 2024 +0200
ath11k: fix monitor mode
Enabling CPTCFG_ATH11K_MEM_PROFILE_512M will change the layout of
struct hal_rx_desc_ipq8074. This broke monitor mode. Fix it by not modifying
the struct even if the 512MB profile is enabled.
Fixes: WIFI-12102
Signed-off-by: John Crispin <john@phrozen.org>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
These packages are required for basic NSS offloading. So ensure they're
selected for all qualcommax targets.
* kmod-qca-nss-ecm (Enhanced Connection Manager)
* kmod-qca-nss-drv (NSS Driver)
* kmod-qca-nss-drv-bridge-mgr (NSS Manager for Bridges)
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Cleaned up erronous settings for disabled features. The syntax should be
"# CONFIG_SOME_OPTION is not set", rather than simply commenting it out.
Removed left over config options from 5.15, and enabled features
recommended by QSDK:
```
CONFIG_IRQ_TIME_ACCOUNTING=y
CONFIG_MULTI_IRQ_HANDLER=y
CONFIG_HANDLE_DOMAIN_IRQ=y
CONFIG_HZ_FIXED=0
CONFIG_NO_HZ=y
```
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Revert to using the default kernel timer (CONFIG_HZ_100).
Setting the timer to 1000hz is unecessary and just adds CPU overhead. It
also causes atomic scheduling issues in various threaded tasks,
especially when using threaded NAPI.
When the kernel timer frequency is set to 1000 Hz, it generates interrupts
1000 times per second. This increased frequency can lead to more
frequent context switches and interrupt handling, which can
interfere with other kernel activities.
Since network packet processing is offloaded to the NSS cores, the main CPU
does not need high-resolution timer interrupts to manage network
traffic efficiently. The NSS cores handle this independently.
This is the setting used and recommended by Qualcomm for all their IPQ
platforms.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Add wake_tx_queue mac op to support AQL and support
txq dequeueing from mac80211. Also implement a
simple scheduler for pulling all skbs from txqs
of all AC's at the end of tx completion NAPI.
Tested-on: IPQ5018 hw1.0 AHB WLAN.HK.2.6.0.1-00861-QCAHKSWPL_SILICONZ-1
Signed-off-by: Tamizh Chelvam Raja <quic_tamizhr@quicinc.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>
qualcommax: NSS: Refresh patches against 6.6.41
Signed-off-by: Sean Khan <datapronix@protonmail.com>
qualcommax: NSS: refresh patches for 6.6.51
Signed-off-by: Sean Khan <datapronix@protonmail.com>
qualcommax: add console-size + increase record-size
Signed-off-by: Sean Khan <datapronix@protonmail.com>
(cherry picked from commit 4ea718f6ebcaadfe6b274b96d9323970151b78f1)
qualcommax: NSS: refresh patches for 6.6.56
Signed-off-by: Sean Khan <datapronix@protonmail.com>
qualcommax: NSS: refresh patches for 6.6.60
Signed-off-by: Sean Khan <datapronix@protonmail.com>
(cherry picked from commit 8efd9fedbff95990ffe192f504491fe63e9a7d55)
qualcommax: Refresh NSS patches against rebase 863d1a63
Signed-off-by: Sean Khan <datapronix@protonmail.com>
qualcommax: NSS: Refresh patches for 6.6.67
Signed-off-by: Sean Khan <datapronix@protonmail.com>
NSS patches should always get applied last as to avoid fuzzing issues
with upstream patches.
Also cleanup patches that introduced spaces as indents vs. tabs
Signed-off-by: Sean Khan <datapronix@protonmail.com>
ath11k_nss: drop upstreamed patch
A variation of this patch 'wifi: mac80211: Use flexible array in struct ieee80211_tim_ie'
was upstreamed in commit 'e6e4d90b69027d74ba7e9a0a586b95a5714e10c0'.
Remove it to avoid compilation issues.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
ath11k_nss: Fix patch conflict
Signed-off-by: Sean Khan <datapronix@protonmail.com>
The following options can now be specified in `pbuf` uci config.
1.) auto_scale (bool) - enable or disable NSS CPU auto-scaling.
default: 'off'.
NOTE: Recommended to leave off, as it locks
NSS core to it's full 1.7Ghz speed. In the past
auto_scaling has been unstable, often causing
kernel panics or connection drops. Qualcomm
themselves disables scaling in QSDK for
ath11k/ath12k/qca-wifi.
It is provided to allow users wanting more
control over power usage. Setting to 'on' also
fixes NSS CPU stats updating properly.
2.) n2h_queue_limit_core0 (int) - set queue limits for CORE 0 and 1.
default: '2048'
For users on low memory systems (<=512M),
that are experiencing issues can try lowering
to the driver default of '256'.
This patch was mostly cosmetic for ipq8074 to supress warnings about
invalid memory region. In this case the M3 dump region. This isn't
necessary for operation or offloading, and is used for firmware
debugging.
However due to the memory layout of ipq6018 it was causing issues of NSS
offloading properly loading. 'idx' shouldn't be incremented, and instead
should just break.
Signed-off-by: Sean Khan <datapronix@protonmail.com>
1. Fix function to check for bridge master status while checking
for Bridge VLAN filter feature is enabled on bridge slave ports.
2. Disable default PVID for bridges during device registration in
the system.
Change-Id: Ibea6559c1b0700a2300b60e20d57b7818e23a8a8
Signed-off-by: Vishnu Vardhan Bantanahal <quic_vishvard@quicinc.com>
bridge: Fix Bridge VLAN stats update
This patch fixes Bridge VLAN stats update for both bridge master
and bridge slave.
Change-Id: Ia26f4c71e83e27dd83336815cda5c05c8c3f24ff
Signed-off-by: Vishnu Vardhan Bantanahal <quic_vishvard@quicinc.com>
bridge: Add bridge VLAN filter APIs for offload for 6.1 Kernel
Change-Id: I54e44c26664f86ae024f54605a032713a9a3eee5
Signed-off-by: Vishnu Vardhan Bantanahal <quic_vishvard@quicinc.com>
Signed-off-by: Sean Khan <datapronix@protonmail.com>