Tx data transfer in host mode with nbuf map_unmap debug frmwk
enabled and enhanced stats disabled results in an assert.
This is because on Tx completion path, nbuf unmap is done using API
qdf_mem_unmap_nbytes_single which takes physical address of nbuf
for unmap and does not remove nbuf from map_unmap tracking list and
when nbuf is freed, it results in assert as the tracking list still
contains that nbuf entry.
In order to fix this, define a new API for nbuf unmap passing physical
and virtual address of nbuf as arguments. Physical address is passed
as an argument in order to avoid cache miss in per packet path which
eventually helps in improving the KPI.
Change-Id: I77ab6ac3ac98556b9caff8aa3ee82bc23cd26de7
CRs-Fixed: 3006671
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
Add support to calculate uplink delay on a per vdev basis.
The delay calculated excludes bus delays, where packet
enqueueing time and complete time are fetched from HW release
ring.
Change-Id: I4bbcbf28b197f7a87cb822a841f1f957ebcf063b
CRs-Fixed: 2958833
If number of entries available in tx comp ring are more
than quota then process number of entries as per quota
Change-Id: I6345cb6f7cee62c343d152f42beb15460ce02ef1
Move DP TX target specific functionality to dp/wifi3.0/be
and dp/wifi3.0/li folders. DP Functionality common to both lithium and
beryllium targets stays in dp/wifi3.0.
Change-Id: I3497284153e2ea30a9cb1faf05bd41422329b804
CRs-Fixed: 2891038
Memory allocated for tx_hw_desc_history uses incorrect
size parameter resulting in much lower memory to get
assigned. This will result in OOB access and corruptions
in memory, regions post the trailing boundary when updating
tx hw desc events via dp_tx_hw_desc_update_evt.
Fix is to use the appropriate memory size for tx_hw_desc_history
and add NULL check in dp_tx_hw_desc_update_evt.
Change-Id: I97af7898cf8bf1b24978d559f84a2a3d00227ed8
CRs-Fixed: 2952859
In some of the targets modulo operator assembly API's
are not defined causing compilation error.
To avoid this use qdf based API's for modulo operations.
Change-Id: Ibc69b69aa38cadff5daa8dee8b65ceaacfe997b7
CRs-Fixed: 2940281
Add the history support to log Tx descriptors programmed
in Tx and completion HW rings.
Change-Id: I60954c93e2595e7dad1251c459eed8afc761e917
CRs-Fixed: 2924614
Currently, excess logging is causing a crash when enqueuing
of Tx MSDU descriptor to HW failed.
Rate limiting the log messages to avoid the crash.
Change-Id: Ibb230ce03c23518b6f7feda61a49bf155c7ddc69
CRs-Fixed: 2933002
a call to osif_proxy_arp need to be invoked inside UMAC_SUPPORT_PROXY_ARP
as it was protected under build macro UMAC_SUPPORT_PROXY_ARP.
Change-Id: I6e165a328ac65fb659cb9fbc3a0ce39fcbb6744b
Add NULL check for function pointer vdev->osif_proxy_arp .
Which is leading to a NULL pointer derefrence error.
Change-Id: I850d10da879231255970572487260e75fe2e3a78
CRs-Fixed: 2909911
Refactor WLAN_FEATURE_PKT_CAPTURE_LITHIUM to WLAN_FEATURE_PKT_CAPTURE_V2
to remove hardware name from compilation flag.
Change-Id: I5a30b33d8bd6065d12e7c89c666c2f0cab66344e
CRs-Fixed: 2869827
In cases like Tx capture or per packet info, need to unmap
before skb is touched. Add wrapper function to do the same.
Change-Id: I0d13b2d90c80972f346f85960b1297511771516b
Use macros like dp_cdp_debug, dp_cdp_err, dp_cdp_info to
print logs for QDF_MODULE_ID_CDP
Change-Id: I550eefa82c3417b8bf83378d4a9c6f382098fea6
CRs-Fixed: 2855937
ME code calls dp_tx_send_msdu_multiple API for Tx the converted
unicast packets. Set nbuf next to NULL before calling ME
convert API to avoid Tx of nbuf->next multiple times
Change-Id: Id063e227b56c494108dc23bd2fdbdc9c085ba4ab
Issue1: Driver RTPM state is ON/NONE, Kernel state is RESUMING.
cdp_runtime_resume is already complete,
hif_pm_runtime_get return -E_INPROGRESS,
dp_tx_hw_enqueue will set the flush event,
but cdp_runtime_resume is already done,
this flush event will be handled only on next pkt tx.
Issue2: Driver RTPM state: Resuming
hif_pm_runtime_get returns -EBUSY,
dp_tx_hw_enqueue is interrupted by any IRQ,
cdp_runtime_resume is completed,
dp_tx_hw_enqueue will set the flush event,
This flush event will be handled only on next pkt tx.
Fix:
Introduce a link_state_up atomic variable in hif to track the link state
change by pld_cb.
Set atomic variable link_state_up=1 in pmo_core_psoc_bus_runtime_resume
just after pld_cb. pld_cb brings the PCIe bus out of suspend state.
Set atomic variable link_state_up=0 in pmo_core_psoc_bus_runtime_suspend
just before pld_cb. pld_cb puts the PCIe bus into suspend state.
Introduce dp_runtime_get and dp_runtime_put.
dp_runtime_get get refcount with increment of an atomic variable.
dp_runtime_put return refcount with decrement of this atomic variable.
If hif_pm_runtime_get returns -EBUSY or -EINPROGRESS,
take the dp runtime refcount using dp_runtime_get,
check if the link state is up, write TX ring HP,
return the dp runtime refcount using dp_runtime_put.
cdp_runtime_suspend should reject the suspend, if dp_runtime_get is non
zero.
cdp_runtime_resume should wait until dp_runtime_get becomes zero or time
out, then flush pending tx for runtime suspend.
Change-Id: I5b97d50cba710082f117f3845f7830712b86cda7
CRs-Fixed: 2844888
Multipass init is called from vdev attach and
multipass deinit is called from tx vdev detach
To maintain symmetry between init and deinit
move multipass deinit to vdev detch
CRs-Fixed: 2840338
Change-Id: I18657497b9e09ec5cc75d245765f6d0fd7d061fd
Currently if the driver is in runtime suspend/suspending
state, any packet transmission will request for resume
via hif_pm_runtime_get.
Unfortunately there is a logging in the above API which
will lead to more time consumption in the NET_TX softirq
context. This can lead to other delay in processing other
softirqs in the system.
Fix this by skipping the logging in the packet transmission
path.
Change-Id: Icc9f5b67794f7666243eb059f2e07a06a987002e
CRs-Fixed: 2844126
Low memory profiles like 256M and 16M profiles support
only NSS Wi-Fi offload mode and HOST data path APIs are
not used in NSS offload mode
Disable HOST data path APIs which are not used in both
NSS Wi-Fi offload mode and in HOST mode (in NSS offload mode)
CRs-Fixed: 2831478
Change-Id: I6895054a6c96bd446c2df7761ce65feef662a3cc
FW uses CCE rule to exception all mcast/bcast frames. Ast_idx
override does not help in sending them to TQM directly.
Change-Id: Iad6c1e8073f5c5d0513adb7097d5024177b7b7f5
Upper layer (OS_IF) can mark certain packets to be sent
to FW. Mark such packets as exception, so that it is sent
to the FW.
Change-Id: I44af2b06793712be7236f831b6b2604123d72bb1
CRs-Fixed: 2813172
Excessive logging was detected in dp_tx_msdu_multiple.
To fix this, Reduce log level when tx_hw_enqueue fails.
Change-Id: I66d58d12aff037896c7623c6755a443092673a88
CRs-Fixed: 2823453
The TX notify comp flag is used only by MCL, hence moving
to the MCL this field to the MCL specific cb private structure.
Change-Id: I707ab9252dea705552df9678eedd8501f479672e
currently qdf_nbuf_len is being used to get the length of
the tx pkt, but this API also interprets the nbuf CB field
to adjust the length if extra_frags are present.
The concept of extra_frags is applicable only for legacy
drivers but in lithium as cb is not reset in the driver the
qdf_nbuf_len API is mis-calculating the length if extra_frag
field in cb is set by any network stack protocol.
To avoid this qdf_nbuf_headlen API is used to get the length
of the TX pkt.
Change-Id: Ie1e0b4b2168daf93ae77f4c995f5c3476a27b433
In HTT MEC notification, wifi vdev should be mapped from
vdev_id provided in HTT WBM completion status word
Change-Id: Ic0a440efdbdc1ee99f27fb4797ee068599d06268
Update log level of peer null check from err to info
in dp_tx_comp_process_tx_status as excessive logging
is detected.
CRs-Fixed: 2811236
Change-Id: I1b0ae723adb90b4b915f11479b5408fde147864c
TSO segment struct is not unmapped and TSO buffer is
not got freed in HW enqueue failure case handler.
Implement similar unmap and free handling as TX comp
handling.
Change-Id: I83389fcc97a2e99497011e9e878f665be88f9f04
CRs-Fixed: 2795836
TSO packet segments are enqueued to the HW individually.
The skb users count is incremented for each additional
segment, so that it is freed only when the TX completion
for the last segment is received.
Currently the skb users is incremented for the additional
TSO segments after the previous segment has been enqueued
to the HW. Due to this, there is a chance for the tx
completion for the first TSO segment to be received even
before the skb users is incremented to account for the
remaining TSO segments, thereby leading to use-after-free
scenarios.
Fix this by incrementing the skb users for additional
TSO segment before enqueueing the previous TSO segment
to the HW.
Change-Id: Idebc28719ba6f0223d5454e15c3cde349803816e
CRs-Fixed: 2801777
Use AST override feature to send out multicast packet in
4 address format. Pass per packet peer_id from osif layer.
Change-Id: Ic86120169c89e7972caa3cc8c967de72670314d0
CRs-Fixed: 2775051
While sending me packets, if failure is encountered
either while preparing tx desc or while enqueuing
to h/w,the cloned nbuf's must be freed.The unmap
must be done only if the failure is encountered
for all the me buffers.
Change-Id: I08dbae1fa1820b4fb31119f65e939aead829321b