Commit Graph

16316 Commits

Author SHA1 Message Date
Harsh Kumar Bijlani
eee813ad02 qcacmn: Initialization of stats in txrx_peer and monitor_peer
* Initialize stats in dp_txrx_peer and dp_monitor_peer as per
  the stats re-organization.
* Update peer calibrated stats on every timer expiry of 1 second.
* Define APIs to reset monitor_peer stats and to fetch rdkstats_ctx
  from monitor peer.
* Place check to make sure that monitor peer related APIs are
  are called only for legacy peer or MLO Link peer.
* Update peer based pktlog flag, tx and rx capture feature flags
  in monitor_peer.

Change-Id: Idadbe19e85d4a9fdf77fb6dabe0c8a4952b024b8
CRs-Fixed: 3092123
2022-02-09 11:54:14 -08:00
Harsh Kumar Bijlani
148f220408 qcacmn: Segregate stats among peer, txrx_peer & monitor_peer
Segregate the stats among dp_peer, dp_txrx_peer and dp_mon_peer
structures.

Segregation is done as per below:
 * Move stats updated in per pkt path to dp_txrx_peer
 * Consider stats updated purely in per pkt path as per_pkt_stats
 * Consider stats for which there is an alternate path of
   updation as extd_stats
 * Move delay stats and jitter stats to dp_txrx_peer
 * Maintain calibrated stats in dp_peer
 * Move rdkstats_ctx from dp_peer to dp_mon_peer
 * Move invalid peer from dp_pdev to dp_mon_pdev

As per the above segregation, if there is not support for
alternate path of stats updation, then stats in dp_txrx_peer is
combination of per_pkt_stats and extd_stats and dp_mon_peer
does not hold any stats.

If support is there, then dp_txrx_peer holds only per_pkt_stats and
dp_mon_peer holds extd_stats.

Change-Id: I2eb81d1b93a178985c05ff4f6557a173cc8a262d
CRs-Fixed: 3092123
2022-02-09 11:54:07 -08:00
Pavankumar Nandeshwar
b9038e9d4e qcacmn: Move per packet stats params to txrx_peer
Move the stats parameters from the dp_peer which are used
in per packet path to txrx_peer

Change-Id: Ieb68b6950740791b37bbd2bfdc4815c3d7bc4834
CRs-Fixed: 3095637
2022-02-09 11:54:01 -08:00
Pavankumar Nandeshwar
98b25a2ee6 qcacmn: use txrx_peer in rx and tx paths
Use txrx_peer in rx and tx data paths instead of
main dp peer.

Change-Id: If628543092be220021240b6f25ee43b009592bac
CRs-Fixed: 3095637
2022-02-09 11:53:55 -08:00
Pavankumar Nandeshwar
826ec6b4f5 qcacmn: use txrx_peer in wds APIs
use txrx_peer in wds APIs instead of main dp peer

Change-Id: I3d05de8c29c1ee012405ca2ab22aec3876956bf1
2022-02-09 11:53:49 -08:00
Pavankumar Nandeshwar
04bb406179 qcacmn: use txrx_peer in defrag and rx error paths
Use txrx_peer in defragmentation and rx error paths instead of
main dp peer.

Change-Id: I95bb2f672e49d0f6ddb94a093688b0fbce5e373d
CRs-Fixed: 3095637
2022-02-09 11:53:43 -08:00
Pavankumar Nandeshwar
9c6800383c qcacmn: Move per packet params to txrx_peer
Move the parameters from the dp_peer which are used
in per packet path to txrx_peer and params related
to monitor path to monitor peer.

Initialize txrx_peer and monitor peers.

Change-Id: I0449c67c1cd47deb76bc89b5ddc64174f6694eb0
CRs-Fixed: 3095637
2022-02-09 11:53:37 -08:00
Vivek
a795c47f70 qcacmn: Add CDP call to configure SAWF
Add CDP call to configure SAWF enable
and disable for a soc.

Change-Id: I42f383a2e33808cf91310fd989a2e12db447236d
CRs-Fixed: 3119127
2022-02-09 07:45:51 -08:00
Vishal Miskin
0f0d23d5cd qcacmn: Defined a driver interface for periodic TSF sync feature
Add a QCA vendor netlink interface to start/stop periodic TSF sync
feature and also support configuration of interval value as part of TSF
sync start command. In addition, improve documentation for the related
attributes and values.

Change-Id: Ia39609a3cc72c0194fe4685e43f08f1c49f8b412
CRs-Fixed: 3108416
2022-02-09 05:31:37 -08:00
Santosh Anbu
2e416b83a2 qcacmn: Support multi ast delete ops callback
Add change to define multi ast delete callback to be used at
CDP OL ops

Change-Id: I4bfcf91a56b65a447f436241021288ba867a43f8
CRs-Fixed: 3124256
2022-02-09 02:06:36 -08:00
Manoj Ekbote
5abebcd1a6 qcacmn: Add sanity check in rx monitor path
Check physical address of nbuf with ring addr. If they
don't match, move to the next descriptor. Activated with
build flag.

Change-Id: Ibd6b38679d677a59f14450db3224104396c88d2e
2022-02-09 02:06:30 -08:00
Ripan Deuri
d66625fbca qcacmn: Add wmi ops to set rate control parameters
- Add wmi pdev param ids.
- Add wmi ops to send set retry thresold, mcs drop value
  and probe intervals.

Change-Id: Ic316337244e8fab07e7ed214c5fe62bf43a827d4
CRS-Fixed: 3126266
2022-02-09 02:06:23 -08:00
Srinivas Girigowda
9630b58469 qcacmn: connection_mgr: Add API ucfg_cm_get_connected_band()
Implement an API to get connected band information.

Change-Id: I682a749d293afd06a4fe12acf985cc5d44d11db8
CRs-Fixed: 3104394
2022-02-08 18:25:29 -08:00
Vignesh U
809a5a3602 qcacmn: Address compilation error in non-6G PFs
The structure members of regulatory pdev private object,
is_6g_channel_list_populated and super_chan_list are 6G specific but are
used outside the 6G macro 'CONFIG_BAND_6GHZ'. It is used in get channel
list API reg_get_pwrmode_chan_list(), that is commonly called for all the
bands.

Move the 6G portion of get channel list API to a separate API
reg_get_6g_pwrmode_chan_list() that is empty for non-6G platforms.

Change-Id: If9aeedbf157536d10912f4ee1d92f42146b19759
2022-02-08 15:05:34 -08:00
Linux Build Service Account
e577592d1a Merge "qcacmn: Add intra-bss check for NAWDS in tx path" 2022-02-08 10:06:15 -08:00
Linux Build Service Account
76bd5c85c9 Merge "qcacmn: Use the correct datatype for wireless modes" 2022-02-08 10:06:13 -08:00
Neha Bisht
8fb88793e5 qcacmn: Add intra-bss check for NAWDS in tx path
In NAWDS, if ast for self bridge is present in AST table,
then the mcast arp frames are getting dropped if peerid
for nawds peer is matching ast peerid of self bridge.
To fix this, add intra-bss check for NAWDS in tx path.

Change-Id: I6f1b44634536c558520aaf0bd0c0155c4b2a4e28
2022-02-08 07:44:46 -08:00
Shashikala Prabhu
4905072179 qcacmn: Use the correct datatype for wireless modes
Wireless mode is of datatype uint64_t but in some places, it is used
as uint32_t.

In this change, replaced 'uint32_t wireless_modes' with
'uint64_t wireless_modes'.

Change-Id: I13b5781ddb14fc0131668e1710df19ae75eb1e34
CRs-Fixed: 3119562
2022-02-08 07:44:41 -08:00
Linux Build Service Account
8ca83f4b45 Merge "qcacmn: Use sw_peer_id instead of ast_index to get peer" 2022-02-08 07:07:59 -08:00
Gerrit - the friendly Code Review server
273f7cd811 Merge changes into wlan-cmn.driver.lnx.2.0 2022-02-08 07:03:41 -08:00
Devender Kumar
d70b48ed27 qcacmn: Use sw_peer_id instead of ast_index to get peer
In order to support flow overide feature,
AST table has to be split between RxPCU and DDR.
With this split, RX monitor cannot make use of
ast_index to fetch peer as it is not from DDR.
So make use of sw_peer_id to fetch peer.
This sw_peer_id is derived from RX_MPDU_STAT_START_TLV
Remove the spinlock on unsused variable i.e ast->lock.

These changes were overwritten by monitor segregation
effort, hence bringing back again.

Change-Id: I339f4296562e3b4dfd6f3a71102385e395f00268
CRs-Fixed: 3108200
2022-02-08 04:36:40 -08:00
Amith A
bf6d8b4a64 qcacmn: Remove duplicate copyright
Remove duplicate copyrights

Change-Id: I7115db15f82df17cc972c76d013008cbaf57b9ae
2022-02-08 02:05:17 -08:00
Adwait Nayak
9a61b83a20 qcacmn: Fix issues in monitor path
1. Replenish path issue:

a. when number of required buffers passed to replenish API is '1',
host does not replenish '1' buffer.

b. If no. of available entries in ring are '0', return sw desc
   back to pool.

2. 32-bit compilation issue

3. Block ppdu desc deliver API when pktlog is enabled for BE

Change-Id: I79ebf1f84830b4c2f5e5b727e3e08c5ee1870898
2022-02-08 00:56:27 -08:00
Ripan Deuri
88a5486b0e qcacmn: Add support to rate control API - rate upper bound
- Add wmi pdev param id.
- Add wmi ops to send set rate upper cap cmd.

Change-Id: I9da42a53f19fec5b98a271165ec5c6bd7c72c4e5
CRS-Fixed: 3123033
2022-02-07 21:26:06 -08:00
Bing Sun
fd0ac6014b qcacmn: Refine 5g bonded channel state with static puncturing
Refine reg_get_5g_bonded_channel_state_for_freq with static puncturing.
Update channel state as CHANNEL_STATE_DFS or CHANNEL_STATE_ENABLE if
its puncture bitmap is valid with given bandwidth.

Change-Id: I3503c8bcf6094b9c98056809f1c304747ba97667
CRs-Fixed: 3106240
2022-02-07 20:22:11 -08:00
Karthik Kantamneni
6423cd35e3 qcacmn: Do not proceed for recovery on TX completion delay
Do not proceed for qdf recovery on TX completion delay.

Change-Id: I09a088c9e1fa78ce1b2013af3cd9ed41207b52ea
CRs-Fixed: 3124692
2022-02-07 20:22:06 -08:00
Vivek
3e7c64225c qcacmn: Add SAWF to init resource config
Add SAWf to init resource config to communicate
to the FW to either enable or disable Service Aware Wifi

Change-Id: I8285e383cb464c506e98e3a88dd267dae4b96558
CRs-Fixed: 3101373
2022-02-07 17:57:02 -08:00
Srinivas Girigowda
1cd2285eca qcacmn: Extract tx complete status based on CDP_ARCH_TYPE
For the non standard htt tx completion, extract the tx completion
status based on the CDP arch type.
For Lithium based architecture, use HTT_TX_WBM_COMPLETION_V2
For Beryllium based architecture, use HTT_TX_WBM_COMPLETION_V3

Change-Id: I050e8a144d72c2a9fcb6174c690c38c4e2c88c25
CRs-Fixed: 3119153
2022-02-07 17:56:53 -08:00
Madhavan Ganesan
ff60b352ba qcacmn: fill BAR address for AHB chipsets
Add function to fill the BAR address for AHB chipsets.

Change-Id: I77610bed6aadf18829367ae7fff2ea32227d8f9a
2022-02-07 17:56:45 -08:00
Jingxiang Ge
bfca76d3b6 qcacmn: Revise LF copyright back
There is no need to update LF date if using QuIC account.

Revise I29b998939cfa25f0547a9871721c6daeb0fdd961.

Change-Id: Id27e90487df4023e45482792e726ba82c59f0b84
CRs-Fixed: 3119512
2022-02-07 16:41:45 -08:00
Kiran Venkatappa
94a233e8e6 qcacmn: Move mlo setup trigger to end of WMI ready handler
MLO setup trigger is required to trigger setup sequence with FW. Move it
to end of the function to ensure that it is always called and skipped
due to goto

Change-Id: I49d096f6e9c4ae0d9ad0de5e1ab32eaaaa3fee2e
CRs-Fixed: 3124260
2022-02-07 16:41:40 -08:00
Vignesh U
2806fac2c3 qcacmn: Add reg_get_pwrmode_chan_list API
Add reg_get_pwrmode_chan_list() which will take an input 6G power mode
and will use super channel list to build the 6G power mode based channel
list.

The 2G and 5G portion of this channel list will be same as the current
channel list and if the input power mode is REG_CURRENT_PWR_MODE, then
also the current channel list is copied to the given buffer.

If the input 6G power mode is REG_BEST_PWR_MODE then all the 6G frequencies
supported by the current country will be present and will indicate the
power values of the best power mode possible for that entry.

For other 6G power types only the 6G portion of the channel list is
modified as per the input 6g power mode.

Change-Id: Ib22399ac950af87ee64ecdb78089bb2ff5221f69
2022-02-07 16:41:35 -08:00
Ripan Deuri
839558bc01 qcacmn: Add support to rate control API - rate upper cap
Add wmi pdev rate config support service id

Change-Id: Ibcb26a63da5ff4999b8837454e7796c7645999fe
CRs-Fixed: 3114432
2022-02-07 16:41:30 -08:00
Rahul Gusain
949beb6cad qcacmn: Send fils discovery template to wmi layer
Add support to send Fils discovery template via target if

Add func to compute shortssid with the help of shortssid table

Change-Id: I78fa50641ee5ae0c338719c4cec91573a212f396
CRs-Fixed: 3114903
2022-02-07 12:27:04 -08:00
sandhu
acd531729d qcacmn: Ext stats optmization , CNE stats
Change Ext stats for msdu_missed to reflect reo error.
Update EXT stats transmit enqueue failure value to reflect
enqueue errors on all transmit rings.

Change-Id: I532b2b0adaa3216809978e3d558a3b11e5bc8eb6
CRs-Fixed: 3115517
2022-02-04 23:06:35 -08:00
Amir Patel
28ecc1a2f1 qcacmn: Add RxMON global enable support
Add RxMON global enable support for WKK

Change-Id: If732318788821303441a5db9ebe21bd2d56b3679
CRs-Fixed: 3123532
2022-02-04 19:55:36 -08:00
Nirav Shah
6340679db0 qcacmn: qdf: Add support to update tsf timestamp in data packet
Add support to update tsf timestamp on driver entry and
exit in data packet. This helps debug latency issue in
XR usecases

Change-Id: I00dcf2416513b94701c11f2a07b2dc74b665f573
CRs-Fixed: 3116365
2022-02-04 07:10:57 -08:00
Nirav Shah
33528eaa41 qcacmn: dp: Add support to update tsf timestamp in data packet
Add support to update tsf timestamp on driver entry and
exit in data packet. This helps debug latency issue in
XR usecases

Change-Id: I9c966c1b8cb09dc5eab6104fdad36c19a1d68045
CRs-Fixed: 3090108
2022-02-04 07:10:51 -08:00
Naga
3e4c2182ff qcacmn: Updated copyright year markings
Updated copyright year markings

Change-Id: I2d70827bf0eaee6741a8b8a1704a8303b6e0cd8b
CRs-Fixed: 3114195
2022-02-04 03:31:42 -08:00
Surabhi Vishnoi
c62b0f215e qcacmn: Reduce the log level from error to info
Reduce the log level of tx flow control threshold pool size
from error to info. This is done to reduce the delay due to
console logging in connection/roaming path.

Change-Id: I5332bd179edc92006976a6421121cfce38b89b70
CRs-Fixed: 3119430
2022-02-04 03:31:37 -08:00
Vignesh U
2b442113ee qcacmn: Address compilation issues
The API reg_get_superchan_entry() is defined under macro CONFIG_BAND_6GHZ,
but used outside it in the API reg_is_freq_idx_enabled_on_given_pwr_mode().

Place reg_is_freq_idx_enabled_on_given_pwr_mode() under the macro
CONFIG_BAND_6GHZ since it is applicable only for 6G and call the API
reg_is_freq_idx_enabled_on_cur_chan_list() for non-6G.

Change-Id: Ieb3efd946f19515dab3fc0c8086e1c508c9f75ad
2022-02-04 03:31:31 -08:00
Srinivas Dasari
c49f8063e7 qcacmn: Move MLO link vdev to UP state upon legacy to MLO roaming
Host driver creates two vdev as part of initial connection.
If the connected AP supports MLO, both(sta and link) of the vdevs
would be moved to UP state. Otherwise, link vdev would be in INIT
state and not moved to UP state.
Firmware sends roam sync indication to host when it roams to a
new AP. The event carries new AP info and the new AP could be
MLO AP. If the current AP is non-MLO and new(roamed) AP is MLO AP,
move the link vdev state to UP as it's in INIT state.

Change-Id: Ib5dd216074d68b0001755024153263ba9654edbe
CRs-Fixed: 3106059
2022-02-03 16:46:15 -08:00
Chaithanya Garrepalli
7852711cd8 qcacmn: Define qdf_nbuf_alloc_simple() in all cases
Define qdf_nbuf_alloc_simple() NBUF debug support is
disabled at compile time

Change-Id: Ie5918d720d8fa861063c46786b01b0d2a644e52b
2022-02-03 11:14:54 -08:00
Ananya Gupta
bb366620fc qcacmn: Check timestamp before calculating time latency
Race condition is observed when runtime suspend is aborted
due to pending tx completions, in this context all tx desc
are checked for corruption or leakage. In parallel tx completion
is received and descriptor timestamp is set to null. As a
result, while checking for leakage in runtime suspend context,
time difference for the tx completion is current jiffies which
is huge, resulting in triggering recovery.
To fix this, tx_desc timestamp is checked before calculating
time latency. Also, printing tx descriptor id for which
completion is not received.

Change-Id: I38b487a47170af374f43c44a96e2a0753f5d57ef
CRs-Fixed: 3117549
2022-02-03 04:06:21 -08:00
Jyoti Kumari
c84369425f qcacmn: Add MLO STA + NAN + NDI service cap support
Add MLO STA + NAN + NDI service cap support

Change-Id: Ia1b839c70b987025f727466a73d2dfa8efe9a8f3
CRs-Fixed: 3120615
2022-02-02 17:11:28 -08:00
Srinivas Pitla
6d7ae524a3 qcacmn: Implement primary UMAC selection based on RSSI
This implements RSSI Primary UMAC selection algorithm for MLO

Change-Id: Ia1901e91e2b6184a5895c4d784425f387cd9474d
CRs-Fixed: 3105927
2022-02-02 13:15:37 -08:00
Adil Saeed Musthafa
40663d0990 qcacmn: For EAPOL packets on MLO, accept EAPOL destined to MLD mac
EAPOL packets on MLO are destined to MLD mac address of the VDEV. So
we have to accept these packets as well, in case of MLO

Change-Id: If424d145341073806ba313f415e88a738360214d
CRs-Fixed: 3121164
2022-02-02 13:15:32 -08:00
Vivek
aa6ee918d6 qcacmn: Rename the MLO multicast macro
There is a difference in the macro used in the
MLO multicast macro used in control path and DP

Changing the macro to be the same as DP code.
Also fixed minor issue in the MLO mcast WMI
identified while testing with the macro enabled.

Change-Id: I0c24a69628336f74d627863dd4bd4c4bef685b6c
CRs-Fixed: 3102733
2022-02-02 12:06:40 -08:00
Tallapragada Kalyan
b265fdd7fc qcacmn: introduce simple nbuf_free API in RX path
simple Alloc is being used in RX path which avoids
certain debug logic. during free of nbuf we should
avoid this debug logic else it will report it as
double free, this will be triggered only when debug
is enabled

Change-Id: Iadb40071fb733cc4de3291784df5075d5a099a8e
2022-02-02 12:06:34 -08:00
Sumedh Baikady
e4d9b0c2d7 qcacmn: REO queue ref enhancement for Waikiki
In WIN BE chipsets, replace the REO tid
queue programming in FW via WMI with writing to a
Host managed table shared by HW and SW. REO HW will
pick the tid queue address from the table indexed by
peer id and tid number.

Change-Id: I8107ca5116425538329b11ae3519f02b32573bac
2022-02-02 12:06:29 -08:00