Commit Graph

389 次程式碼提交

作者 SHA1 備註 提交日期
Yu Tian
ed3ba3ca44 qcacmn: Replenish more RX buffers when refill ring runs low
When nbuf allocation failure happens, there is no retry scheme.
So RX buffers in refill ring may shrink and not got enlarged.
This change is aimed to replenish more RX buffers when watermark
is less than critical low threshold.

Change-Id: I201b9e252ba08ba1bff47e0b5ec819a45f1b1ddf
CRs-Fixed: 3245915
2022-08-11 12:43:23 -07:00
Tallapragada Kalyan
cea862a118 qcacmn: map tx ring to get_cpu instead of skb queue
skb queue is not always mapped to the proper CPU
hence it is good to map the ring_id to CPU through get_cpu
API.

Change-Id: I3bf76452cc1fcb2033ef1a8640c4dd31ecba61b3
CRs-Fixed: 3255144
2022-08-08 13:07:35 -07:00
Ming Jiang
53537c67e1 qcacmn: Support none 4k page size kernel
DP uses multi page allocation for tx/rx descriptor.
ID and offset mask of decriptor is based on 4096 which
couples with Kernel's MMU PAGE_SIZE. This cause trouble
when deploy driver on none-4K page size kernel.
Set qdf_dp_blockmem_size to 4096 so that DP won't
depend on kernel page size.

Change-Id: I17f5c10b394e8709e6b4b153f3dd094cf792787f
CRs-Fixed: 3235246
2022-08-03 05:29:55 -07:00
Jinwei Chen
64d7493b30 qcacmn: add RX statistics per lmac for MLO connection
Add RX statistics per lmac for MLO connection.

Change-Id: I72b942732cc362c1613fae637bc5e1154f9e2ec2
CRs-Fixed: 3251609
2022-07-29 22:57:35 -07:00
Neha Bisht
173f9e6b1d qcacmn: Use cpu index for tx. ring id
The list of SW descriptors that we create from the HW descriptors 
in DP Tx completion path is corrupted in intra-bss path. This is causing a
crash when corrupted descriptor is accessed.
The cause of corruption seems to be due to incorrect rings being accessed. 
Use cpu index to fetch tx. ring IDs.

Change-Id: I5342b7c4e24df983900fde79f36df8395bf628cb
CRs-Fixed: 3223420
2022-07-27 09:25:33 -07:00
Chaithanya Garrepalli
b34fe34b48 qcacmn: Add WAR to get the vdev in invalid peer path
For QCN9224 splitphy mode do not rely on rx_desc_pool_id
to get to the VDEV as desc pool is common across PDEVs

Change-Id: I2552878bd56696a8df463b35e2b273ed4e591050
CRs-Fixed: 3220690
2022-07-27 05:36:47 -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
Sai Rupesh Chevuru
bedd18fa8b qcacmn: Enable NO_RX_PKT_HDR_TLV
Unsubscribe the PKT HDR TLV in RX path.

Change-Id: If37102569ba1963efd743c6508dc9c835b49bf01
CRs-Fixed: 3229821
2022-07-19 05:19:20 -07:00
jinbliu
a8f2b81354 qcacmn: Skip special frame rate info update
To avoid unmeaningful rate fluctuation, when report
rx linkspeed to upper layer, exclude special frames:
arp/ssdp/dhcp/eapol/ipv6 NA/NS/DHCPV6 in low rate.

Change-Id: I4bc49a808a02b4bc8c687f70690922045d65e739
CRs-Fixed: 3198484
2022-07-15 13:35:11 -07:00
Amir Patel
09ae481644 qcacmn: Use page_frag_cache to avoid fragmentation
Use page_frag_cache to avoid memory fragmentation
in WKK RxMON

CRs-Fixed: 3234833
Change-Id: I2e42a41999694a91b0f3f9386a1ad0c691bf5caf
2022-07-15 05:01:37 -07:00
Jinwei Chen
9d2b26795a qcacmn: add 11be TX/RX rate statistic support
Currently 11be msdu rate statistic is not supported yet.
Another issue is: HW reported pkt type value 6, while host
SW defined 11be type DOT11_BE (value 5), they are not matching.
DOT11_BE value 5 is referred in monitor mode and otherwhere,
so do map and conversion in host sw side.

Change-Id: Ic5c2dd2a35cbe0ecd6430f007b6e7e02ece40998
CRs-Fixed: 3230900
2022-07-05 03:19:03 -07:00
Chaithanya Garrepalli
bd0375c2de qcacmn: Remove unnecessary checks in Tx path
1. Remove prints in per packet path
2. Add prefecth for skb shinfo
3. Avoid qdf_get_cpu() in DP tx

Change-Id: I86d196cc7865a2d5b3a5a6098f6f7d84397a60d0
CRs-Fixed: 3227568
2022-06-28 14:00:52 -07:00
Srinivas Girigowda
c8fafae5ee qcacmn: Remove irrelevant qdf_assert_always()
For non-self sta peer (sta_self_peer is set to 0) and in error cases
like (WMA peer create failure), peer->txrx_peer is NULL which
indicates DP peer setup has not happened and therefore there are
no rx cached frames flush. Having a qdf_assert_always() if sta_self_peer
is set to 0 is incorrect. This a valid scenario.

Hence remove the irrelevant qdf_assert_always().

Change-Id: I1ab18dd681534bb9257be388a74adedc529a67cf
CRs-Fixed: 3212253
2022-06-13 17:50:06 -07:00
Subrat Dash
46d50239e8 qcacmn: Microsecond time stamping for hw tx latency stats
Use microsecond timestamping for the tx descriptors
for capturing the latencies more accurately. It will help
to determine the appropriate bucket.

Change-Id: I216e083a7c89b01b6f2f384c1c0a85ca323d3a3e
CRs-Fixed: 3165153
2022-05-16 17:18:48 -07:00
Surabhi Vishnoi
ecaa0f1f6c qcacmn: Allow rx UDP packets during roaming before peer map is received
In VoIP cases, no or minimal packet drop is expected during
roaming. Currently, data packets are dropped in host if they
are received after roam sync indication from firmware and before
peer map indication is received due to invalid peer.
This change allows rx UDP data packets during roaming before
peer map indication is received from FW if peer's auth_status
received in roam_sync_indication from FW is authorised.

Change-Id: Ic518b7cd0aef48a2b0f8c923a2e20838b07f3d1f
CRs-Fixed: 3168603
2022-05-12 23:34:21 -07:00
Jinwei Chen
5f37239c73 qcacmn: Fix SAP DHCP ACK no TX Comp notify issue
When TX completion is released from FW, dp_tx_notify_completion()
will not be invoked, then TX DCHP ACK will miss
hdd_softap_notify_tx_compl_cbk() which then
WMI_PEER_CRIT_PROTO_HINT_ENABLED with value 0 will not send to FW.

(1) move dp_tx_notify_completion() from dp_tx_comp_process_desc_list()
to dp_tx_comp_process_tx_status(), so that both TX completion release
source FW or TQM case will call it.
(2) clear TX notify flag for intra-bss forwarding BC/MC to avoid
unnecessary TX completion notify.
(3) Set ts.status for release source FW case otherwise it will be value
0 always.

Change-Id: I2bf9900a3d16ba162a83b061f0b96e7d2f79423a
CRs-Fixed: 3178423
2022-04-21 03:20:36 -07:00
Yeshwanth Sriram Guntuka
df666b7116 qcacmn: Add support to enable tx hw latency stats at run time
This feature can be enabled runtime using sysfs interface.
Support is added to dump and clear the histogram stats.

The lower delay regions has to be more granular to indicate any
medium related issues for time sensitive XR applications.

Change-Id: I0a44a54d12d92ce016de349810cb2bedebaf9a58
CRs-Fixed: 2981006
2022-03-24 06:47:10 -07:00
Ananya Gupta
42dd66b280 qcacmn: Allow all OOR frames to deliver to stack
Few APs are sending bar frame right after sending a
packet but the packet is not received and its retry
is received with the same sequence number. As SSN
is moved ahead due to bar frame, this packet is being
dropped.
To fix this, allow all frames to get delivered to stack.

Change-Id: I17f7126c8d318415e88b037b72563cf53cb14066
CRs-Fixed: 3151908
2022-03-21 13:09:13 -07: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
Neha Bisht
229317b922 qcacmn: Avoid intrabss check in Tx NAWDS path
Intrabss check for NAWDS was added as a temporary fix to resolve the
issue of selfbridge enteries present in AST table. The actual reason
is loopback pkt received with one's own bridge mac. To avoid this, add
a check for not sending out any packet with an invalid peer id in the
ast table.

Change-Id: Ia4c520bcc8b7077f0b484a0bc40c4d26db77c3f4
CRs-Fixed: 3135142
2022-03-03 02:11:13 -08:00
Pavankumar Nandeshwar
223693e614 qcacmn: Handle nawds case of intra-bss forwarding
Handle nawds case of intra-bss forwarding of
multicast packets on Beryllium.

Change-Id: I05ec4d937b4b97aa2c9fb325fb2b6a197968ea2a
CRs-Fixed: 3103402
2022-03-01 00:14:42 -08:00
Mohit Khanna
211fb195c9 qcacmn: Support for MIN rates for criticial frames
Add support in BE to send special frames(EAPOL, ARP, DHCP) at minimum
rates.

Change-Id: I2c141cd8ef16d93fb9e99d7c48dd921913627b0b
CRs-Fixed: 3114311
2022-02-24 01:00:12 -08:00
Pavankumar Nandeshwar
e157e0df4e qcacmn: Flush dp cached frames only for mld peer
Flush dp cached frames only for mld peers and legacy peers, as
link peers don't need it.

Change-Id: I19a27c5810a1fec6a62bfe5a6377073dc382fb4c
CRs-Fixed: 3131405
2022-02-17 09:40:38 -08:00
Pavankumar Nandeshwar
d5a07afa5d qcacmn: WAR for invalid length buffers in wbm rx error path
WAR for wrong length in first msdu in wbm rx error path while
handling scatter gather buffers. Get the msdu length from the
last buffer instead.

Change-Id: I869391ef5ca7005dce972013679c2143be836ecb
2022-02-10 01:38:15 -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
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
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
Pavankumar Nandeshwar
d9e6722ff0 qcacmn: Fix QUIC Copyright Markings
Fix QUIC Copyright Markings

Change-Id: Id0cea92c1e6b64f82601c08a81b6246ee6d49a62
2022-01-27 12:53:33 -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
Chaithanya Garrepalli
2c1ccc9baf qcacmn: Fix NAWDS mcast loopback issue in intraBSS
For NAWDS intraBSS mcast traffic add check for SA
and DA peer to avoid loopback

Change-Id: Ifb987dbfe6d6f427cd8873315d4ffd67390b4e6f
2022-01-03 01:03:59 -08:00
sandhu
ad2829718c qcacmn: Remove IP from files
remove IP from code

Change-Id: If119a4af213b10aadb9f1344e50b0342e72405c2
CRs-Fixed: 3073864
2021-12-29 04:28:58 -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
Chaithanya Garrepalli
97a1c8bff1 qcacmn: Changes to caluclate soc max peer id
Changes to caluclate max peer id in case
of MLO

Change-Id: Ib52cfb4f92eafb88689774e8e6c406751d30372a
2021-12-02 06:06:47 -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
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
Mohit Khanna
9d2cde1128 qcacmn: Add last TX/RX timestamp in DP peer stats
Add timestamps for last TX/RX in peer stats. This stat is needed to be
passed on to upper layers on demand.

CRs-Fixed: 3059712
Change-Id: If0d8b7dc3c139e4d1b670bf98f3f574f02ea9715
2021-11-08 05:19:46 -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
Chaithanya Garrepalli
3c3e5709ac qcacmn: Increse num TX rings for QCN9224
This change includes below
1) Changes needed to increase Tx rings to 4
2) Use WBM2SW4 ring for rx error in QCN9224
3) memset srng at alloc to avoid populating RBM_id
in per packet path and enable implicit RBM

Change-Id: Icbd5ac2378273b8f3c6adc41c611e29551fff22f
2021-10-13 13:12:19 -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
Yu Tian
9fa8dd3bc3 qcacmn: Correct pkt length check for scatter frame rx
When a scattered frame is received, msdu length caclulation
is incorrect, this leads to while loop can't break. At last
skb, null pointer dereference happned. Change is aimed to
correct the length caclulation.

Change-Id: Ifb316f004ea5829b1130ce4c0fc9253134e26713
CRs-Fixed: 3025973
2021-09-17 03:40:58 -07:00
Harsh Kumar Bijlani
a7e391e49f qcacmn: Remove WDI event WDI_EVENT_UPDATE_DP_STATS from per pkt path
WDI event WDI_EVENT_UPDATE_DP_STATS is triggered for updation of peer
stats from both per packet and monitor path wherein per packet path is
applicable for MCC and monitor path is applicable for WIN.

Trigger for this event is flag protected under the macros
FEATURE_PERPKT_INFO and WDI_EVENT_ENABLE.

FEATURE_PERPKT_INFO is not defined for MCC.
With this, WDI event in per packet path is not triggered and hence unused.
Make changes to remove the unused code.

Change-Id: Ibcb0948b0ecae313270b6a173e243b2f27f1bbee
2021-09-08 14:55:32 -07:00
Shiva Sankar Gajula
dcbdb29d04 qcacmn: Register separate function pointer to receive EAPOL frames
Add changes to register separate function pointer to receive EAPOL
frames instead of using regular RX path and adding export symbol
for __qdf_nbuf_data_get_eapol_subtype() to access in it multiple
modules

Change-Id: Id05b982d31a7e008536d10dd5281e88cceba96db
2021-09-07 07:59:06 -07:00
Surabhi Vishnoi
9aaf9e8110 qcacmn: Remove rx packet capture events processing if feature is disabled
Currently, rx packet capture events processing happens even
when feature is disabled by ini. This incurs per packet overhead
in rx path.

The fix is to move all the processing from rx path to packet capture mode
component. Send only wdi event from rx path, when feature is enabled by
ini.

Change-Id: I647256b85117cd3373950c78a5a0ae7d6710e4e2
CRs-Fixed: 2969123
2021-09-03 03:25:02 -07:00
aloksing
b158abe417 qcacmn: API renaming for monitor module
Add prefix dp for all monitor APIs
Add mon_debug/mon_info/mon_err for logs

Change-Id: I71d49f6bcacd77f5695269817fed83337169227b
CRs-Fixed: 3006497
2021-08-12 05:32:47 -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
c60b9619a3 qcacmn: Conditionally compile monitor related features and issue fixes
PATCH[7/7]:
This patch consists following changes:
 -Conditionally compile all monitor destination ring related code
  Macro used QCA_MONITOR_PKT_SUPPORT
 -Add QCA_ENHANCED_STATS_SUPPORT macro to conditionally compile
  enhanced stats support
 -Use QCA_MCOPY_SUPPORT and QCA_TX_CAPTURE_SUPPORT macros
  to conditionally compile MCOPY and Tx capture features
  respectively
 -Use QCN_IE macro to conditionally compile BPR
  feature
 -Use QCA_ADVANCE_MON_FILTER_SUPPORT macro to conditionally
  compile advance monitor filter feature
 -Fix vdev attach issue for special and smart monitor vap
 -Fix status ring initialization issue.

Change-Id: I0deaa28a9a54bf34b0f41e6dd510fdd8d4992db2
CRs-Fixed: 2983780
2021-07-30 21:51:26 -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
aloksing
e7cc727374 qcacmn: Move core monitor and monitor dependent feature func
PATCH[4/7]:
This patch consists following changes:
 - Move core monitor and monitor dependent feature functions
   to monitor file
 - Move enhanced stats functions from htt to monitor file
 - Move vdev set monitor mode rings function to monitor file
 - Create and initialize relevant funct ptrs
 - Initialize cdp monitor related ops.

Change-Id: Iac1ab43eb1c4b98bd21bbb8a5741ee53034da2f1
CRs-Fixed: 2984635
2021-07-30 21:51:12 -07:00