Correcting an earlier commit 4beda3ab66
to consider all the cases where the avl entry needs be deleted when
a scan is either completed or aborted for any reason.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
Radio was falling back to original channel after switch because
of a mismatch in radio state and radio config.
Updated the radio config with “switch-to” channel to match with the radio state.
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
Sometimes, the driver reports 0 Noise Floor value which is
not a valid data point. Adding a workaround in Opensync layer
to consider previous recorded NF value when 0 NF is reported.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
Successive scan requests on same interface cause scan timeout.
Scan requests are enqueued at the Opensync layer and is designed
to handle the requests sequentially. If there are successive
scan requests for the same interface, then we end up deleteling
an on-going scan context. This is due to the interface name being
used as key for the AVL entries, and we were trying to reuse the
AVL entry if one already exist.
Solution is to always allocate a new entry without any reuse.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
For RRM noise floor driven channel change:
1. Set HT VHT HE based on the hw_mode
2. Set secondary frequency (center_freq1) based on bandwidth
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
The data from the chan_info events were overwriting the data
to the existing survey info counters. The data in the chan_info
events were Read-On-Clear where as the Survey info was maintained
as incremental stats and the application in the User space
performs the calculations based on incremental survey info stats.
As an example, the survey->time was always stored as 150 due to
chan_info event's Clear-On-Read nature. And this lead to the
difference calcuation as 0 at the User space application.
Solution is to add the incoming chan_info data to the existing
survey info stats, instead of replacing the existing data with new.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
Query the driver and update the wifi_associated_clients list
during wm initialization.
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
- AP was not reporting the Channel Tx power currently set in
the firmware. This patch reads the Tx power from debugFS stats
and reports it to cloud through Wifi_Radio_State table
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
Associated clients list decrements when client roams
from vifX to vifY. In this case, the client is
first added to the global client list as part of it
associating with vifY (but in actual it doesnt add as
the entry for client already exists) and then deleted
from the same as part of dissassociating from vifX.
Fix is to change the vif the client entry points to
instead of add/delete the client entry.
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
Some client events are duplicated and some of them are missing in the
client event report.
Root Cause 1: Processed clients events were not tagged in hostapd and
were thus getting duplicated during subsequent polling of client events.
Root Cause 2: Race between processing and clearing of client sessions
was leading to missing events.
Solution 1: Processed client events are tagged in hostapd and are reported only once.
Solution 2: Sessions are cleared only after they are processed by SM.
Also got rid of some unnecessary logs.
Acceptance Criteria: No duplicate client events in the mqtt report send by AP.
Sessions in the hostapd are successfully cleared after being processed by SM.
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
Add support for changing mcast and beacon rate
in opensync for ath11k
Add debugfs entry for ath11k driver to set mcast,
beacon and mgmt rate.
For help:
cat /sys/kernel/debug/ieee80211/phyX/ath11k/set_rates
Eg: Set beacon rate to 12Mbps for iface wlan0 5G band
echo "wlan0 beacon 5 0x10000002" > /sys/kernel/debug/ieee80211/phy0/ath11k/set_rates
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
The TP-Link device mounts the production_info partition, and apnos will
access the manufacturing data and copy the certificate to its use when
it is first booted.
Signed-off-by: Arthur Su <arthur.su@tp-link.com>
wifi-2984: tplink device mount manufacturing data and certificates
The EX227 and EX447 devices are added ath11k_generate_macs method.
Signed-off-by: Arthur Su <arthur.su@tp-link.com>
Inconsistency(gaps in reporting) was noticed when metrics were observed
for 24 hours.
Root Cause: One of the sockets created and used in SM for periodic network-probe reporting
was not getting closed. Due to this system wide limit for maximum open file descriptors
was getting exhausted over a period of time and thus not allowing to create any more
sockets to send data.
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
1. Set HT VHT HE based on the hw_mode
2. Set secondary frequency (center_freq1) based on bandwidth
3. Add HE parameter in ubus call switch_chan
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
Under Bridged mode of configuration, when creating VLAN interface,
we create VLAN for both WAN and LAN side, whereas LAN side VLAN is
not requried.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
This Patch fixes leds incorrect service state issue, and correct the
label names for all wifi6 APs
Signed-off-by: Nagendrababu <nagendrababu.bonkuri@connectus.ai>
- Currently ath10/11k reports time_bss_rx (amount of time the radio spent receiving data on a local BSS)
inside time_rx (amount of time the radio spent receiving data). This patch fixes the behavior.
- Added support to report time_bss_rx over nl80211
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
Channel time, busy and other survey counters are showing incorrect values (less than previous or sometimes zero).
Consecutive survey dumps are expected to return monotonically increasing counter values.
Root Cause:
Clear on read in ath10k was leading to this issue.
Solution: Use the non-clearing
WMI_BSS_SURVEY_REQ_TYPE_READ wmi_bss_survey_req_type
Note: ath11k already has this fix.
Patch also fixes the utilization percentage calculation for different survey parameters in opensync
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
Sometimes we see a Client session created with sessionId=0,
and this never gets deleted. The AP keep on sending this event
as long as it exist in the events list.
SessionId=0 is invalid. Adding checks to avoid creating session
with Id=0. Also added a check in the opensync ubus to skip
already processed events.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
Add rrm channel setting through radio config. This
allows channel change through radio config in the
case where vif is not reloaded.
The below commit disables reload of vif when setting
RRM parameters:
"wifi-2648:Config RRM params without wifi vif reload"
Signed-off-by: Ammad Rehmat <ammad.rehmat@connectus.ai>
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
Configure the following without vif reload:
Tx power
probe_response_threshold
client disconnect threshold
Beacon and multicast rates
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
This patch will add the conditions to respond captive portal API's to
only valid configuration
Signed-off-by: Nagendrababu <nagendrababu.bonkuri@connectus.ai>
Mismatch in vifC and vifS for captive portal is
leading to opennds restarts and memory leakage.
Fix by making sure the vifC and vifS are in parity.
uci_blob not being freed, fix by making uci_blob
as global so that it need not be freed and can
be reused instead.
Signed-off-by: Chaitanya Godavarthi <chaitanya.kiran@netexperience.com>
Cleaning up captive portal code to improve stability and reduce memory leaks
Signed-off-by: Nagendrababu <nagendrababu.bonkuri@connectus.ai>
- During the configuration process, AP was triggering network
and wireless reload multiple times in a very short window
resulting in a poorly configured hostapd. This patch makes sure
that network/wireless is reloaded only once after all the configuration
is committed to UCI files.
Signed-off-by: Yashvardhan <yashvardhan@netexperience.com>
When the manufacturer block does not contain the model info,
it is then extracted from /tmp/sysinfo/board_name, stripped
off the manufacturer name and converted for all upper case string.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
Applying the user configured dwell time for off-channel scan
requests. This needed driver changes to accommodate the command/event
processing time in the configured scan timeout, otherwise the scan
is aborted resulting in no off-channel survey results.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>
This fix applies to EA8300, WF194c and EAP102. For these APs,
the br-wan is mapped to eth1 instead of eth0. Adding fix to
use the mac address from eth1 as ID for these particular APs.
Signed-off-by: ravi vaishnav <ravi.vaishnav@netexperience.com>