提交图

53 次代码提交

作者 SHA1 备注 提交日期
D Harilakshmi
82bd3d9009 Revert "qcacmn: Optimize DP Rx Error Handling (Part-2)"
This reverts Change-Id:	I760694073a06c1829f28e7e92cd1657560d8eb06

Change-Id: If1573653da912702bd343acfa42f9ae32a3f7844
CRs-Fixed: 3472220
2023-04-26 06:39:59 -07:00
Kenvish Butani
969c5bdf1f qcacmn: Optimize DP Rx Error Handling (Part-2)
In WBM2SW Rx Error path for BE
specific functionality
1) HAL API's/Function pointers are replaced
with specific function calls.
2) Efficient read/write of WBM Error Info
from HAL Rx desc.
3) Minimize reading data from Nbuf TLV.
4) Peer_id fix for MLO clients with security

Change-Id: I760694073a06c1829f28e7e92cd1657560d8eb06
CRs-Fixed: 3472220
2023-04-20 13:29:39 +05:30
Kenvish Butani
711fb71599 qcacmn: Revert "Optimize DP Rx Error Handling (Part-2)"
This reverts the commit.

Change-Id: Ia1a304daa5d63a063bfc2d22b9b99ccad02af0e1
CRs-Fixed: 3472017
2023-04-19 05:43:51 -07:00
Kenvish Butani
d0d9a987fc qcacmn: Optimize DP Rx Error Handling (Part-2)
In WBM2SW Rx Error path for BE
specific functionality
1) HAL API's/Function pointers are replaced
with specific function calls.
2) Efficient read/write of WBM Error Info
from HAL Rx desc.
3) Minimize reading data from Nbuf TLV.

Change-Id: Ic8793ffcbeb2411c9b81fb32acae062e8a1f40cc
CRs-Fixed: 3362828
2023-04-07 09:13:49 -07:00
Tallapragada Kalyan
e4798ea69b qcacmn: optimization changes to improve RX KPI for WIN
done the following changes to improve the RX path KPI
	1. remove the extra invalidate in RX path as
	we no longer dirty the RX TLV cache lines.
	we now store the rx error codes in nbuf cb instead
	of RX TLVs reserved memory bytes.

	2. with features like flow tag and wds extended mode
	enabled by default, the rx_fast_flag is always set
       	to false, this resulted	in lot more instructions
       	being executed in RX path.
	Now we ensured this flag is at least set for other
	features which are not enabled by default.

Change-Id: I04c6bdc52a2b3f1248b822a108d8bd1a70abcc7c
CRs-Fixed: 3406505
2023-03-30 02:32:40 -07:00
Sai Pratyusha Magam
d2952c2e85 qcacmn: Remove wapi packets from is_eapol check
Remove wapi frames from is_eapol check in dp_rx_null_q_desc.

This change is to address the below issue:

First wapi packet received in dp_rx_nll_q_desc,
before TID setup does not reach stack since it is
treated as an eapol frame and gets dropped in
dp_rx_eapol_deliver_to_stack.

Change-Id: Ibcad786eb1a1cec1c082ec630ea38cc582627dfa
CRs-Fixed: 3413689
2023-03-24 07:23:46 -07:00
Chaithanya Garrepalli
97fcc90a7e qcacmn: Handle SG case with multiple MSDUs in MPDU
In case of where multiple scatter gather frames are
part of same MPDU last_mpdu_in_msdu will be set only
for last buffer of last scatter frame in MPDU.

Below is the hw descriptors bits when 2 scatter frames
are part of a MPDU

 -----------------------------------------------------------
|Buffer_num | MSDU_NUM | first_in_mpdu | cont | last_in_mpdu |
 -----------------------------------------------------------
|    1     |     1    |       1       |  1   |      0       |
 -----------------------------------------------------------
|    2     |     1    |       0       |  0   |      0       |
 -----------------------------------------------------------
|    3     |     2    |       0       |  1   |      0       |
 -----------------------------------------------------------
|    4     |     2    |       0       |  0   |      1       |
 -----------------------------------------------------------

In above case scatter MSDU boundary checks can be done only
based on continuation bit. So while reaping use continuation
bit instead of last_in_mpdu bit to detect boundary

Change-Id: I42e7360d6a1b7d0cfd9a6688cae51e3854d430ec
CRs-Fixed: 3388668
2023-03-10 16:11:55 -08:00
Kenvish Butani
7fdd918e7f qcacmn: Add Support of Rx MLO Link Stats for ML Peer
Add Support to update Rx per packet path, MLO Link
stats for ML Peer

Change-Id: Ica25993126b4ce49f9e36b7b290d9887e4885155
CRs-Fixed: 3397721
2023-03-08 07:42:17 -08:00
Kenvish Butani
3243b9e4f4 qcacmn: Add Support of Rx Err MLO Link Stats for ML Peer
Add Support to update Rx Error path, MLO Link stats
for ML Peer

Change-Id: Ie5000d0d30a41fa69c86259bae0fd7a8094bddf7
CRs-Fixed: 3397721
2023-03-08 07:42:07 -08:00
Kenvish Butani
2fbc8c8ab0 qcacmn: Optimize DP Rx Error Handling (Part-1)
1) In WBM2SW Rx Error path, code to reap and
the process the HAL descriptor is split into
BE and LI architecture specific functionality
in dp_be_rx and dp_li_rx files respectively.
2) The function to handle Null Queue desc.
error for WBM and REO Rx Error path is split
into BE and LI architecture specific
functionality in dp_be_rx and dp_li_rx files
respectively.

Change-Id: Ic51a9742f65cee677ed7f3081f49fb3ece5b42f1
CRs-Fixed: 3356179
2023-02-07 07:00:22 -08:00
Jeff Johnson
4f341433ba qcacmn: Fix dp/wifi3.0/li documentation
The kernel-doc script identified a large number of documentation
issues in dp/wifi3.0/li, so fix those issues. In addition, there are a
number of instances where public functions have their implementation
documented instead of having their interface documented, so move that
documentation.

Change-Id: I38f98ebaa5373338cdff68dbde5c0d66780413c2
CRs-Fixed: 3373156
2023-01-24 04:48:53 -08:00
Yu Tian
efd6e156da qcacmn: Force invalid check for every pkt
Normally TID is obtained from MPDU start pkt and is performed
invalid check. There is a chance that DUT receives an
aggregated MPDU with invalid TID, TID value is not updated for
the second MSDU, then it will lead to OOB access.
Change is aimed to perform the check for every MSDU.

Change-Id: Ie261ddbc0e9dcd10459c68d3c78e13faa70286ac
CRs-Fixed: 3333265
2022-11-16 11:51:08 -08:00
Sai Rupesh Chevuru
12c8b0d0be qcacmn: compact tlv support for QCN9224
Adding compact tlv support for QCN9224, As part of this change
Rx tlv size will reduce from 384 bytes to 128 bytes.

Change-Id: I3f42a781e42b2e696a5b25d9c5f333c8cc83b7fe
CRs-Fixed: 3274152
2022-10-14 23:42:02 -07:00
Sai Rupesh Chevuru
431514912a qcacmn: SG support in RX path
Process the sg frames received in RX path.

Change-Id: Ia2d83c75c46f804599ca8fda4668c43ee508d59e
CRs-Fixed: 3303055
2022-10-14 08:31:27 -07:00
Nirav Shah
a87c585e12 qcacmn: Extend add timestamp logic for Beryllium
Extend add timestamp logic for Beryllium

Change-Id: I69604b83ce5fe7f112316148213d73fefc88ba9b
CRs-Fixed: 3245806
2022-08-02 01:14:53 -07:00
Amit Mehta
7e799fcbae qcacmn: Fix Rx packet logging issue
Currently while sending nbuf to rx fate logs
we are not removing rx tlv before sending nbuf
to logger which is causing issue of incorrect
packet type issue.

To Fix issue make changes to make sure that
rx tlv is removed and nbuf length is set

Change-Id: Ib56c8e009398b3410c43be910feb4048bfb06b54
CRs-Fixed: 3241828
2022-07-24 23:07:50 -07:00
Jinwei Chen
9b323ded29 qcacmn: Support RX T-put simulation for KIWI
Duplicate X times of RX packet before delivering to stack, if OTA
RX T-put is 100 Mbps and try to simulate 200 Mbps RX T-put,
duplicate extra 1 time RX packets, this is aimed to test
driver/stack RX capability.

Change-Id: Iaf4db05d0ec0e0cda5fac19fa63b9d3133270847
CRs-Fixed: 3132743
2022-07-24 01:02:01 -07:00
Venkateswara Naralasetty
1702cefb57 qcacmn: Skip invalid Rx descriptor access in wbm err process
There is a possibility where host can receive invalid SW cookie
from Rx rel ring which causes invalid rx descriptor access in
dp_rx_wbm_err_process().

Add a sanity check on received SW cookie to prevent the invalid
rx descriptor access.

Change-Id: I7818290466a2a8cea9938577fbf869d1fc30d5e3
CRs-Fixed: 3240038
2022-07-15 07:15:57 -07:00
Amit Mehta
6b576c65bb qcacmn: Add packet logging support for initial 32 packets
Add packet logging support by registering
Rx and Tx callback functions for packet logging of
initial 32 Tx and Rx packets.

Change-Id: I91b59b7c5f65f505e3ee730c497347be28955128
CRs-Fixed: 3224881
2022-06-23 07:03:56 -07:00
Ananya Gupta
8565e7029f qcacmn: Register DP, HTC, HAL modules with Runtime PM module
With restructuring in HIF runtime PM module, modules are
required to register with the HIF runtime PM module. Also,
changes are done in functions of allowing and preventing
runtime PM suspend as part of restructuring.
This change registers DP, HTC and HAL internal modules
with runtime PM module and update HIF runtime PM function
calls with the restructured code of HIF runtime PM module.

Change-Id: I8899a1d3b92a90a05c5eaf4df7609f4008f739f8
CRs-Fixed: 3169372
2022-06-18 23:11:24 -07:00
Pavankumar Nandeshwar
649873d3a1 qcacmn: Decrement quota for all packets in rx process
Decrement quota and num_pending for all packets in
rx process

Change-Id: I296c7bc2590cc388ce24cc75455b62656434f2af
CRs-Fixed: 3137924
2022-03-08 21:03:53 -08:00
Jia Ding
d40b388d2f qcacmn: Mark first packet after wow wakeup
Add feature support to tag first packet that wakes up HOST from WoW.

rx_pkt_tlv.rx_msdu_end.reserved_1a field is used by TARGET to meet
such request.

Change-Id: I3d37e13e8cff49bc4f622d3070a19e4c4be56417
CRs-Fixed: 3137621
2022-03-03 07:22:05 -08:00
Pavankumar Nandeshwar
9979d1a189 qcacmn: Initialize txrx_ref_handle for whunt bypass
Initialize txrx_ref_handle for whunt bypass,
Which is complaining use of uninitialized txrx_ref_handle,
as it is not able to detect that txrx_ref_handle is
populated from another API.

Change-Id: I0f69cf4c8442a5655559622a5825d7af35b9ae5e
CRs-Fixed: 3127788
2022-02-11 04:13:31 -08:00
Harsh Kumar Bijlani
93cd9e0af8 qcacmn: Update stats in dp_txrx_peer in per packet path
Update stats in dp_txrx_peer in per packet Tx completion and
Rx path.

Change-Id: I807cb5ca9fe2aeeabdd4cb95d6e30cb9781560f4
CRs-Fixed: 3092123
2022-02-09 11:54:46 -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
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
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
Tallapragada Kalyan
ab28074b13 qcacmn: Access peer and its parameters only if peer_id changes
1. avoid accessing CFG parameter in per pkt path.
2. Access peer, vdev and pdev only when current peer_id
   is different from previous peer_id.
3. Avoid HKv1 and v2 checks in WDS learning path.

Change-Id: Id7fb7a29c642480f8ca58738dbb0c92130e44ecd
2022-01-24 17:00:31 -08:00
Tallapragada Kalyan
9639c91317 qcacmn: buffer replenish and reap without map and unmap
use dma_inv_range call instead of dma map and unmap
APIs during replenish and reap. This complete code is
under a compile time macro.
before change: 4160Mbps @ 96.5% (core 3)
after change: 4160Mbps @ 90.5% (core 3)

Change-Id: I61bca349a369ace06cd86f353880108cee013cb1
2022-01-20 10:01:09 -08:00
Yeshwanth Sriram Guntuka
de814c9b16 qcacmn: Trace del reg write, ce tasklet latency, tx, and rx pkts
Use the tracepoints to trace delayed register write, ce
tasklet scheduling latency, tx, and rx packets.

Change-Id: I63a89276177a9d0466dcb0c831eeb8e938a2bf79
CRs-Fixed: 3081870
2021-12-14 21:22:49 -08:00
Manoj Ekbote
80e882aa2a qcacmn: Intra-BSS changes for MLO
Use chip ID and destination peer to determine the target soc
and partner vdev for Intra-BSS in MLO case.

Change-Id: I709c52e74426c5e81b50c8063cad7669c0e7002d
2021-12-14 18:13:29 -08:00
Tallapragada Kalyan
fdef41b4a2 qcacmn: Add sanity check for ring descriptor address
in some corner cases (ex: SG frames are received) we
do not decrement quota or num_pending and go and fetch
the next descriptor, chances are ring may not have valid
descriptors at that point of time hence added this sanity
check.

Change-Id: I6994cc69c35de6bed7a71adca0a1d66ed5c94d3c
2021-12-04 14:08:24 -08:00
Harsh Kumar Bijlani
af17c944fb qcacmn: Rx stats changes for BE HW vdev stats
Following peer stats are updated in per packet Rx path:
    to_stack
    multicast
    broadcast

In BE architecture, HW provides the support for basic vdev stats and
hence per packet stats updation of above parameters can be done only
when enhanced stats is enabled or HW vdev offload stats is disabled.

Avoiding per packet stats updation reduces CPU load and improves KPI.

Change-Id: Id7c11c025a8464951b615a7f7b006ce61db487fc
CRs-Fixed: 3067843
2021-11-30 00:58:04 -08:00
Tallapragada Kalyan
4e7ceff561 qcacmn: Prefetch RX HW desc, SW desc and SKB in pipeline fashion
Prefetch RX HW desc, SW desc and SKB in pipeline
fasion in the first loop of RX processing.

This has improved TPUT by 200Mbps and provided a
10% gain in CPU (single core)

PINE with other optimizations: 3960Mbps @ 100% core-3
PINE + pipeline prefetch: 4130Mbps @ 90%  core-3

Change-Id: I47f351601b264eb3a2b50e4154229d55da738724
2021-11-22 13:36:33 -08:00
Tallapragada Kalyan
e3c327a0ba qcacmn: do a batch invalidation of REO descriptors
Added an API to do a batch invalidation of REO descs
saw an improvement of 40 to 45 Mbps.
Note: this change is applicable only for cached
descriptors

PINE with Default driver: 3189 @ 100% core-3
PINE with skb prefetch: 3469 @ 100% core-3
PINE with skb pre + batch inv: 3506 @ 100% core-3
Change-Id: Ic2cf294972acfe5765448a18bed7e903562836c3
2021-11-22 13:36:28 -08:00
Yu Tian
ef29d92da0 qcacmn: Add a tid check for RX to avoid of OOB access
Tid in RX frame header may be larger than MAX TID allowed
value, this will lead a out of boundary array access and
lead to kernel crash at last. Change is aimed to do a TID
check and discard such frame when necessary.

Change-Id: Ie9e7a1816d197d05cf845e81251ef7772721b849
CRs-Fixed: 3071743
2021-11-17 04:36:19 -08:00
Jinwei Chen
9b26ed4fbf qcacmn: Avoid SW AST table accessing for MC/BC frame
For DA MC/BC RX frame, host should not use da_idx to access soc->ast_table
as this da_idx is not valid, OB accessing might happen.

Change-Id: I5c78d869e32536effe2635e561cb6881cdc97c38
CRs-Fixed: 3072841
2021-11-12 16:37:12 -08:00
Jinwei Chen
7e267e17b1 qcacmn: support MLO intra-bss forwarding
Support MLO intra-bss forwarding

Change-Id: I7ffd54bbead3e56c7811e88aef935867b0ee4fd6
CRs-Fixed: 3066899
2021-11-10 03:56:09 -08:00
Pavankumar Nandeshwar
146d67af95 qcacmn: Avoid using ast_entry in intra_bss handling
Avoid using ast_entry in intra_bss handling, instead use
da_peer_id directly from the msdu_metadata

Change-Id: Ic586f297e8e393504d7d399cff7a67c3035aa11f
2021-10-29 07:25:10 -07:00
Jinwei Chen
b521830197 qcacmn: get sw_exception from reo dest ring descriptor
sw_exception bit will be marked in reo dest ring descriptor for
FW re-injected frame, get this bit and save it in skb->cb,
this bit value can be used for FISA further check.
there is no reo_dest_indication field in reo dest ring on beryllium,
so share same cb member for sw_exception and reo_dest_indication.

Change-Id: I2321121be7dda68ed19faca177d868c7e8ba1dbf
CRs-Fixed: 3056156
2021-10-28 10:21:20 -07:00
Tallapragada Kalyan
5026c5a3d3 qcacmn: Add nbuf and nbuf->data prefetch in Lithium RX
Adding a nbuf and nbuf->data prefetches in 2nd loop
of Lithium datapath RX improved UDP throughput by
about 250Mbps.
PINE default driver: 3189Mbps @ 100% core-3
PINE with prefetch:  3469Mbps @ 100% core-3

Note: PINE reo ring is mapped to core-3.
Change-Id: I7f166b52c3697facdce3954994755c9c1412c1f3
2021-10-25 07:47:11 -07:00
Rakesh Pillai
57e2c01e5e qcacmn: Peer id parsing changes for beryllium
Take care of the MLO peer bit indication to be
concatenated with peer_id to access the peer map
object.

Change-Id: Ia603a728101e83829a8906d1b847f42389e78ca6
CRs-Fixed: 3039326
2021-10-15 13:13:27 -07:00
Pavankumar Nandeshwar
26c6cd1397 qcacmn: Enable intra-bss in Waikiki
In Beryllium the HW does the ast lookup and match
and sets the intra-bss bit in the msdu_desc_info
structure of reo_destination ring and WBM Rx release ring.

So, change the Beryllium code to make use of this
hardware assistance for intra-bss.

Change-Id: Ic7c89efc741fefe35603082309204fbe3c9a97c7
2021-09-24 18:28:07 -07:00
Subrat Dash
9a6927e4ed qcacmn: Add check to discard multicast echo packets
The bridge forwards the multicast packets to all the
interfaces attached the bridge.

When the STA network interface receives such packets
from bridge and send it to the AP, it is echoed back
from the BSS.

These packets are not intended for the bridge as it
will lead to looping.

Add a check to detect and drop such packets when
received back from the BSS.

Change-Id: I5a4a2a3e015df2b9c78de405d7d917216baed051
CRs-Fixed: 2997189
2021-08-10 15:39:32 -07:00
aloksing
53fe7000ba qcacmn: Move monitor related fields from soc/pdev to mon_soc/mon_pdev
PATCH[6/7]:
This patch consists following changes:
 -Move monitor related pdev variables to struct dp_mon_pdev
 -Move monitor relted soc variables to struct dp_mon_soc
 -Move cookie to monitor link desc va to monitor file
 -Add APIs to access monitor related variables
 -Add dummy APIs to build without monitor support.

Change-Id: I032a480b1383d061f984cee3ba6b10ac7a0ff350
CRs-Fixed: 2983781
2021-07-30 21:51:21 -07:00
Nandha Kishore Easwaran
a7c7531e90 qcacmn: Allow all raw frames without any check
Allow all raw frames to the upper layer without checking
for port authorisation. All checks in raw mode has to be performed
by the controller in case of raw mode.

Change-Id: Ica6df24b359790fcadc9bb7bbb4d7b5084930170
2021-07-17 03:57:36 -07:00
Yeshwanth Sriram Guntuka
5246cc0bf2 qcacmn: Assert only when unmapped is true in rx_desc
The existing assertions for unmapped variable in
rx descriptor results in an undesired bug_on since
the unmapped value is 0 for active descriptors.

The fix is to modify this assertion so that bug_on will
be triggered only if the unmapped value is 1 in rx
desc.

Change-Id: I03b27e0e42ce3c42b9fa148da9258063b0209b08
CRs-Fixed: 2985248
2021-07-08 00:11:22 -07:00
Rakesh Pillai
5605d45923 qcacmn: Add near-full irq processing handler for RX ring
Add the handler to process the near-full condition
on the rx ring.

Change-Id: I426480386c4716702f8410ed87c70160decaa03f
CRs-Fixed: 2965081
2021-06-30 13:48:07 -07:00
Jinwei Chen
4083155141 qcacmn: Add support for HW cookie conversion
Support HW cookie conversion for BE platform.

Change-Id: I39058fbf256266557f5e734ba376db4db0731b24
CRs-Fixed: 2929533
2021-06-23 23:32:49 -07:00