Some AP disables AMSDU in BA256 mode, this has draw back
with KPI in HE mode, so leave a config field to use 64 BA
forcibly to make high KPI with these types of AP
Change-Id: Ia69ffe118fd5bbda78cfb98126a483fcf305294e
CRs-Fixed: 2828304
Currently the rx tids are getting setup for the
self peer in monitor mode. This leads to sending
commands to the reorder-hw and the hardware generates
its responses.
In Monitor mode, none of these rings are reaped, since
the reorder-hw is not used. This opens up a possibility
of backpressure on the reorder-hw rings.
Skip setting up the rx tids for monitor mode
self peer, since they are not used.
Change-Id: I37bade9ef5c8bd536a01371cc059ebbcfb85ee5a
CRs-Fixed: 2815866
In teardown API update logical delete state to peer
before deleting AST entries of peer. Also in delete
AST API use __dp_peer_get_ref_by_id to get the peer
Change-Id: I6db227a284cf3726cc241ebc98386230eca58fcf
The logging macros implicitly takes care of embedding function name
in the log, hence there is no need to include __func__ again.
Getting rid of redundant __func__ reduces driver memory footprint.
Change-Id: I26bfac840ac6732ac83fb008db8e1702996eb21e
CRs-Fixed: 2774457
With new design, peer is deleted from hash table in
cdp_peer_delete. Hash table search in dp_peer_can_reuse
API at cdp_peer_create will always fail
Update the peer reuse logic to search from inactive list.
Insert peer to inactive list from cdp_peer_delete() and
in peer reuse case search in inactive list to get
peer.
Also add a new lock to protect peer state transition
Change-Id: I2e672fc4a9346c95d67716d437538dd0f96b2207
In the scanerio where peer teardown and peer map happen
in parallel, AST entries could get added to the peer AST
list after cleanup happens as part of peer teardown. AST
cleanup as part of peer unmap handling would not remove
the entry from the peer AST list. This is because
dp_peer_get_ref_by_id returns NULL as peer state is moved
to logically deleted state.
Fix is to not take peer ref by id and use the peer
argument passed in which already holds ref in the
peer unmap handling.
Change-Id: I844d3f07e9eec962d44bbfba851ad46f350e4f97
CRs-Fixed: 2766779
Currently the rx tid spinlock is destroyed from
peer delete (based on peer state) or peer unmap handler.
This can lead to a race condition when the peer is
deleted before the peer map command is processed/received.
Fix the above race condition by destroying the rx tid
spinlock only when the peer handle is destroyed/freed.
Change-Id: Iaf7ccea11a95732c1aa20e66af6dd4a9a66517c5
CRs-Fixed: 2763533
In roam HO failure, peer unmap indication is processed
even before Host initiates the peer cleanup. In the cleanup,
as part of cdp_peer_teardown, AST entries are freed up without
removing it from the peer AST list since get_peer_by_ref_id
returns NULL peer pointer as peer is moved to inactive state.
Fix is to delete peer AST entries as part of peer unmap
indication so that the entries are removed from the AST list.
Change-Id: I1b04517e8cc392b33bb439501e61e3d5534d8307
CRs-Fixed: 2763825
In cdp_soc_deinit peer hash table is freed to add
check to avoid NULL access from CDP APIs which may do
peer hash find
Change-Id: I47c4126c34bb64d43112a4f8e268da1a98f4124d
Add debug support for VDEV refcount to take
refcount by module id and decrement corresponding
refcount with same module id
Change-Id: I15c075816994ba70155fefbc0bce208b20fb9a59
Add new API dp_vdev_get_ref_by_id() which will return vdev
pointer by holding a reference. Caller of this API has
to ensure that this reference is released by calling
dp_vdev_unref_delete() API
New lock soc->vdev_map_lock is introduced to protect
vdev id to object array
Change-Id: I883e328932e35ef31254125492dbae20cebe0e00
Add new APIs to iterate through the vdev peer list
by taking the peer reference.
A call back has to be passed to these APIs which will
be called for every peer in the lisst
dp_vdev_iterate_peer() -> iterates through peer_list of vdev
dp_pdev_iterate_peer() -> iterates through peer_list of all
vdevs in pdev
dp_soc_iterate_peer() -> iterates through peer_lists of all vdevs
in soc
Additonal APIs are added to for itearations where the callback
will be called outside the vdev->peer_list_lock, as these APIs
have additional memory allocations suggested to use only in case
the iteration need to happen outside lock
dp_vdev_iterate_peer_lock_safe()
dp_pdev_iterate_peer_lock_safe()
dp_soc_iterate_peer_lock_safe
Change-Id: I24632fe611355cc3e93b7f16d90913d4b8686ca9
Remove the peer backpointer in ast entry and store
peer_id instead
Assign peer_id in AST entry in AST MAP event,
also add the ast entry to peers ast list
In AST map & AST unmap APIs use ast find by vdev_id
Change-Id: I74d9828dc309149d98f6f577b5c8304cb087fd76
Add support to get the peer reference with module id
To help debug the peer reference related issues
Change-Id: Ie20c7e710b9784b52f2e0f3d7488509282528a00
Use unified version of dp_peer_find_by_id API
which will take peer reference
Also use unified peer ref release API dp_peer_unref_delete
Change-Id: Ibb516a933020a42a5584dbbbba59f8d9b72dcaa4
Update peer DB as per new design
peer_hash_table: add at peer_create and delete at peer delete
peer_id_to_obj_map: add at peer map and delete at peer unmap
peer_list: vdev level peer list add at peer create delete at
peer delete
Call dp_peer_cleanup() at unmap event
dp_peer_cleanup -> dp_peer_tx_cleanup -> Tx capture cleanup
|
---------> dp_peer_rx_cleanup -> Cleanup Rx REO TID queues &
defrag queue free
Introduce ref_cnt variable per VAP which will be
incremented and decremented at peer alloc and free. This counter
will be used to delay the vdev free if there are any active
peers for vdev exist in system
Change-Id: Iec13bceed0db0db71655fdbf6f96df8795b5077b
Remove the global soc->peer_ref_mutex lock to protect
peer access
Instead use granular locks to protect the individual
peer DBs
1) soc→peer_hash_lock : To protect peer hash table
2) soc→peer_map_lock : To protect id to objmap array
3) vdev→peer_list_lock : To protect vdev level peer list
Change-Id: I9f044c4d71fe1155817a2b22a5a050545ec37445
UPDATE_RX_REO_QUEUE commands are queued in the REO_CMD
ring as part of peer cleanup for each tid. The cb
registered defers pocessing the entries in the
reo_desc_freelist based on either number of pending
entries or time threshold. In the scenario when
these entries from the freelist are processed as part
of next disconnection and if the REO_CMD enqueue fails,
the while loop over reo_desc_freelist does not exit
and will end up in a perpetual loop.
Fix is to break from the desc_freelist loop on REO
cmd enqueue failure.
Change-Id: I18ee31ec6a6150cd6952903cc154634b7de4ce60
CRs-Fixed: 2751223
Remove self and BSS peer back pointers and added APIs to
get self and BSS peer from VDEV
These new APIs will iterate through peer list and return
the appropriate peer by taking a reference
Caller has to take care of releasing the reference
Change-Id: I550ff83d665f3ad0a185bea1a1e6270c5474ff07
Notification is sent in following two scenarios.
- After call to dp_peer_add_ast() if we are not expecting any
peer map event.
- When HTT peer map event is received.
Change-Id: Id926d1cec1ee64520b0368fcc5000988c24e0513
CRs-Fixed: 2745542
Handle invalid HW ast index case inside function dp_peer_map_ast().
This change aids upcoming feature where status of HMWDS ast add is
reported to upper layer. This change eliminates extra peer ast list
traversal required for the new feature.
Change-Id: Ic6f45fedb53204c52719686aee9a90ae12695d09
CRs-Fixed: 2728611
Allocate/Deallocated the peer extended object in the
peer_create() and peer_del() paths respectively.
Change-Id: I3e93e1ec85aefb22d3fb40d1b01bbd07d660aff5
In lithium a peer will have only single peer_id hence remove
peer_ids array from dp_peer structure
Change-Id: Ib98270b7fd98f1199b862e4608f990687914b7cc
Suspicious dereference of pointer 'pdev' by passing argument
to function 'dp_find_peer_by_addr' in dp_register_peer.
Add NULL check before dereference of pointer 'pdev'.
Change-Id: Ibe2db784287ff1557aec983829781378578016c0
CRs-Fixed: 2668253
Validate number of wds entries deleted during peer unmap
handling with the number which firmware has sent in
peer unmap message, which indicates the number of
wds ast entries deleted by firmware after peer delete.
Change-Id: I09e1c41bab19cd023e7a83baf1e90d51aab4229e
CRs-fixed: 2667445
- For directly connected peers, during peer de-auth,
a Single Peer delete request to the FW from host
should delete all AST entries attached to the peer.
- This optimization is aimed at optimizing host-fw
handshake messages
Change-Id: Iaebe2022f90ef9a10a6a0f37b21c409cf9e9ea39
CRs-fixed: 2647242
The peer rx packets should be flushed when
deleting the peer and its state should be reset
to DISCONNECT, when deleting the peer.
If the state of peer is not set to DISCONNECT,
then the flushing of rx packets for the peer
which is being deleted will call the rx callback
and submit these packet to the stack, which can
cause unwanted behaviour.
This way the UMAC does not need to specifically
call clear peer before deleting the peer.
Change-Id: I3b5a737126350a361d968f6349aef6291b2e3f56
CRs-Fixed: 2659629
Is some cases, FW wants to adjust BA session parameters
FW sends a HTT event and HOST helps to send out DELBA
and modify BA win size in the next round of ADDBA req/resp
exchange to reduce following RX AMPDU aggr-size
Change-Id: I97777ff59a18346f2cd4e2e562c8ae6acdcd69d7
CRs-Fixed: 2644641
MCL path add the desc back to freelist when FLUSH
failed. It may cause the CMD pending in free list
is even larger than REO_CMD_RING max size and lead CMD
flood then cause REO HW in an unexpected condition.
So it's needed to limit the number REO cmds in a batch
operation.
Change-Id: Ib6b97f0693feb7bb5829bda4683248b495b6c7b3
CRs-Fixed: 2642516
Send peer_id in peer_add_wds_entry API of ol_if_ops,
so that the dp peer doesn't need to be explicitly
retrieved in corresponding offload API.
Change-Id: Ia32d31946de43e9faa1970f4e74f2810f4125995
CRs-fixed: 2629475
Peer key security type is set in cdp_set_pn_check,
this API is called in key install step, but only
update Ucast field even if in Mcast key install.
This may be set wrongly if Ucast and Mcast security
modes are different. Add a new API to set
security modes of differ key types separately.
This change should be reviewd in associate with
review #3036742
Change-Id: Ib9723416fbedbe3dce61224928d51ef203cf7068
CRs-Fixed: 2623114
Currently when checking for duplicate peer, only the vdev
id on which peer is going to be created is checked and not
on other vdev ids. So correct it by iterating over all
vdev ids.
Change-Id: Ie05ecc125d3285a522021b630fc7244501b6a797
CRs-Fixed: 2629146
There is possibility that DUT receives non-aggr frames
with non-aggr SN during BA setup during BA session
setup. SSN updates when ADDBA req is processed, should
also update REO SSN one more time when ADDBA resp sends
This will let REO to be able to receive frames in BA
session with new SN.
Change-Id: I4791bcd6f1ede90615c883d31426fcdecd50a631
CRs-Fixed: 2623505
Host queries for reo hw stats by sending reo queue status command
on all the rx tids. After sending host waits to receive for all the
rx tids reo hw stats. If the hw stats reo status is not received for
all the rx tids with in the specified timeout value corresponding
peers's reference is released. In parallel if disconnect happens
from userspace, there is always a chance to access the freed rxtid
reference in rx hw stats callback. So in case of rx hw stats event
timeout ignore processing the reo command status rx stats callback.
Change-Id: I0aba346a25564a3c29751f1f5a1d4e9204b93d33
CRs-Fixed: 2619720
Peer key security type is set in cdp_set_pn_check,
this API is called in key install step, but only
update Ucast field even if in Mcast key install.
This may be set wrongly if Ucast and Mcast security
modes are different. Add a new API to set security
modes of differ key types separately.
Change-Id: Icaa63139d117de75633ca1f81eb618c6b9294b53
CRs-Fixed: 2617461
Increase the peer ref count before requesting for reo
queue stats and release the ref count after receiving
the queue stats on the reo status srng.
Change-Id: Ife3b87951e767414efa1bfb45486cd364578d2a7
CRs-Fixed: 2604862
Replace QCA_WIFI_QCA8074_VP with CONFIG_WIFI_EMULATION_WIFI_3_0
since VP platform is not being used anymore.
Most of the parameters present inside QCA_WIFI_QCA8074_VP are related
to emulation timeouts. Hence replacing it with a more meaningful flag.
Change-Id: I22a0e5803e765333947f1613b376dcc6bd25b5af
AST entry delete logic has some conditional checks making code with respect
to HTT V1 and V2 messages making it tough to follow.
Change-Id: I229324446134b32021a956fb689e4726256fcc28
Lithium HW can parse each MSDU when packets are enqueued to transmit
classifier and each MSDU can get enqueued to different MSDU-Queue.
By default, there are 2 queues per TID – UDP and NON-UDP. Based on
the flow parsing, packets will be queued to either of them.
Enterprise customers uses RAW mode frames which transmit classifier
would not be able to identify L4 protocol for UDP or NON-UDP queue
for encrypted frames.
Customer can also have different application based packets which needs
to be enqueued to differently prioritized queues. They can choose to
tag each MSDU based on application DPI and derive the flow priority
as below –
• UDP
• NON-UDP
• HI-PRIO
• LOW-PRIO
Customer needs API support from host which will provide an ast-index
based on a particular flow id given peer mac address. Based on the mac
address, host will find the associated peer and return the ast_index &
cache set number corresponding to the flow id from peer flow based ast
entry table. Customer will then program this ast-index and ast override
in transmit classifier CMD ring to enqueue MSDU to a specific
flow-queuein TQM.
Host API:
Input parameter – uint8_t *peer mac address, uint8_t flow id
Output – uint16_t ast_index
Change-Id: I79557c31532514ad5ec0c1848827a3e5cd91cdf2