Debug framework for tracking the SMMU mapping and unmapping of
skb buffer when IPA offload is enable and IPA_SMMU_NBUF_TRACKER
is define.
CRs-Fixed: 3255423
change-Id: I8966097945b33cb866f4642b98b3d1a4beabfad7
In IPA offload, both tagged and untagged traffic cannot be handled with
a single rx pipe. Hence, add support for 2nd RX pipe for tagged and
untagged traffic respectively.
Change-Id: I77ff633327696f66df42fb592492321c1591646b
CRs-Fixed: 3226021
As part of IPA offload support for WCN7850 chipset, properly define
TX ring indexes into soc->tcl_data_ring[] and soc->tx_comp_ring[]
used by IPA.
In the change, use wlan_cfg_get_rbm_id_for_index() to get correct
rbm values for WBM2SW ring used by IPA.
Change-Id: Ie5b6743c1cb2adfa156735fc84dc1429a67f833a
CRs-Fixed: 3246038
To support WDS feature in IPA driver, WLAN needs
to update the ast entry for any new rx packet, and for
end-nodes connected via repeater to root.
CRs-Fixed: 3226348
Change-Id: I7383b12f18e7c70ec06499d66130667eca033131
After enable and disable of both radio, If second radio is enabled
then the instance_id from wlan driver is passed wrongly to IPA driver
which is in leading to initializion of first radio on IPA driver side.
Fix is to take the instace id based on psoc id and set the prod and cons
pipes based on instance_id instead of IPA given handle.
Change-Id: I26f4f3fbd23284e79a380d212ad07aceac50f053
CRs-Fixed: 3179306
2x_pdev changes are include for support new IPA API's
and change the existing API's argument to support new
parameter which is ipa handle, create a new API to get
the IPA hdl from IPA component in DP
Change-Id: I3d2b378620dbd1e64d295623534126e0eebc2d28
Rx patch changes for multichip MLO
1. Create ini for rx ring mask for each chip
2. Configure hash based routing for each chip based
on lmac_peer_id_msb
3. Peer setup changes to configure lmac_peer_id_msb
to enable hash based routing
4. Rx Replenish changes to provide buffers back to owner
SOC of reo ring
Change-Id: Ibbe6e81f9e62d88d9bb289a082dd14b4362252c4
While Rx buffers are getting umapped from net rx context if IPA
pipes are enabled at same time from MC thread context this is
leading to race condition and IPA map/unmap is going out of sync.
To fix this introducing IPA mapping lock and IPA mapping need to
be handled with lock held.
Change-Id: I9fa71bdb6d4e4aa93fc795cc5dd472a181325991
CRs-Fixed: 2945063
Depreciated IPA APIs are currently getting compiled.
To fix this, adding linux kernel version check
Change-Id: I2288db34c09d60047c67a5df9081de08a6c2f62b
CRs-Fixed: 2927413
Currently a set of IPA2TCL and WBM2IPA rings is used for
IPA TX data path. Issue is when wlan is configured as
SAP-SAP DBS mode, slow 2G traffic will consume much more
TX resources and thus 5G traffic will have starvation,
which leads to severe degradation of DBS KPI.
Therefore separate IPA2TCL (SW2TCL2) and WBM2IPA (WBM2SW4)
rings are added to support alternative IPA TX pipe for 2G
traffic.
Change-Id: I4b648d0bcacbcde0b9b0a824516c1f06e3b0c7ad
CRs-Fixed: 2750079
REO remap register direct writes as part of SAP stop could
result in a NOC error if the UMAC is in low power state.
Fix is to use shadow register writes for REO remap and
WBM HP registers.
Change-Id: Ie515c3d28f4ccdd99a3757808f1ab6c5cf373e3d
CRs-Fixed: 2813105
wlan Tx completions doorbell is rung after IPA pipes are disabled
To fix this, Check if tx completions are pending before disable IPA
pipes.
Change-Id: I1903e593cd6a546a277979073f0a9ba62b681644
CRs-Fixed: 2796989
Add apis to map generic registers to shadow region. Existing
logic includes mapping only srng based regs to the shadow
region.
Add support to map REO control regs and WBM2SW2 rel
ring HP reg address to the shadow region in case the direct
reg writes in IPA enable/disable autonomy fail due to UMAC
block being in a power collapsed state.
Shadow reg mapping for these regs is provided to FW during
init. Add stat shadow_reg_write_fail to track shadow reg
write failure and shadow_reg_write_succ to track successful
shadow writes.
Change-Id: I04790765a3de80047689657e2cad0b73123440b9
CRs-Fixed: 2790321
A htt message arrived after ipa context is freed as part of
deinitialization which was dereferenced by event handler
assigned to pdev->ipa_uc_op_cb, resulting in crash.
To fix this, during deinit pdev->ipa_uc_op_cb is deregistered
and assigned NULL before freeing up ipa context.
Change-Id: I8125cb104a538e88cda93960f7443129fabd850a
CRs-Fixed: 2793295
Add API to do IPA Tx buf SMMU-S1 unmapping and register it
with cdp ops for Hastings, also assert if map/unmap failed.
Change-Id: I4071b5fccd84c3c97b9dccc40c6f798d70993189
CRs-Fixed: 2792170
During driver initialization, IPA TX and RX doorbell registers
are provided to wlan as physical addresses. With SMMU S1 enabled,
they're mapped to IOVA of wlan domain.
On driver deinit path, do smmu unmap for the two IOVA addresses.
Change-Id: I85ef1c3e99bef504abf09eebf9ace760b68f35f1
CRs-Fixed: 2768303
Register IPA ready callback with IPA driver. The callback
sets ipa_is_ready flag in the host driver and kick starts
the ipa init sequence as part of which the Tx buffers are
mapped to IPA.
None of the IPA APIs are invoked until IPA ready registration
is complete.
Change-Id: I6570b2b347052164a274fbc22358ebf0719dcabf
CRs-Fixed: 2735107
Memory optimization of unused TX rings by not configuring rings that are
not being used. Configure 2 rings for host in the case of IPA, instead
of configuring 3. If IPA is disabled then configure only 1 set of TX
rings for host.
Change-Id: I251606c728f3020a13e45e8c8386970c8a641f0a
CRs-Fixed: 2530572
Currently cdp ops are given pdev/vdev/peer
handle as its arguments, which is directly
accessed in those APIs. This can cause a
race-condition in access of the respective
handles if it has been deleted in parallel.
Hence as a part of cdp convergence, pass only
the pdev_id or vdev_id or peer mac address,
which will be used to get the respective handles,
and hence avoiding the unwanted access of the
handles if it has been deleted.
- ipa_get_resource
- ipa_set_doorbell_paddr
- ipa_set_active
- ipa_register_op_cb
- ipa_get_stat
- ipa_tx_data_frame
- ipa_uc_get_share_stats
- ipa_uc_set_quota
- ipa_enable_autonomy
- ipa_disable_autonomy
- ipa_setup
- ipa_enable_pipes
- ipa_disable_pipes
- ipa_rx_intrabss_fwd
Change-Id: Ieb7e48d11a69a1e4a92a7114042b1db72d5f4b65
CRs-Fixed: 2540862
Currently for REO reinject path, first fragment is in the
linear part of the skb buffer while other fragments are
appended to skb buffer as non-linear paged data. The other
point is that for REO reinject buffer, l3_header_padding is
not there, meaning ethernet header is right after struct
rx_pkt_tlvs.
Above implementation will have issues when WLAN IPA path is
enabled.
Firstly, IPA assumes data buffers are linear. Thus need to
linearize skb buffer before reinjecting into REO.
Secondly, when WLAN does IPA pipe connection, RX pkt offset
is hard-coded to RX_PKT_TLVS_LEN + L3_HEADER_PADDING. Thus
need to pad L3_HEADER_PADDING before ethernet header and
after struct rx_pkt_tlvs.
Change-Id: I36d41bc91d28c2580775a1d2e431e139ff02e19e
CRs-Fixed: 2469315
For MDM platforms, set default REO destination
ring to SW4 for STA vdev, which is same as SAP vdev.
Note that RX hashing is still enabled for STA vdev.
Also REO destination are run-time remapped when IPA
automony is enabled and disabled.
Change-Id: I49fa523673e7b736008679adec55821e198e8417
CRs-Fixed: 2456786
Observed that when IPA offload is enabled, RX packets
are not routed correctly to IPA ring. Currently only
IX0 of REO_DESTINATION_CTRL_IX registers are remapped,
which only covers 3-bit reo_destination_indication of
range 0 to 7.
Fix is to remap REO_DESTINATION_CTRL_IX2|3 registers
so that reo_destination_indication of range 16 to
31 can also be routed REO2IPA ring when IPA offload
is enabled. Upon IPA offload is disabled, save values
of IX2 and IX3 are reset back to HW.
Change-Id: I3428b450ab10076d27c7628a3729e8cec088bd94
CRs-Fixed: 2434331
Support WDI 3.0 SW path intra-bss forwarding. Major
difference for WDI 3.0 is the metadata info passed
from ipa driver in skb->cb[].
Previously intra-bss fwd decision is done by FW and
it passes fw_desc to IPA where IPA driver passes onto
WLAN driver. Now for WDI 3.0, FW is not involved in RX
path and SW path intra-bss fwd decision has to be done
in wlan driver.
Change-Id: Ibc2246620490905fd992a2df31cc6f241cc63592
CRs-Fixed: 2432831
Support WLAN IPA WDI 3.0 with SMMU-S1 enabled. Key design
considerations are captured below.
- ring base addresses are passed as struct sg_table and IPA
driver will do the IOVA mapping to IPA domain.
- ring doorbell addresses are passed as physical address and
IPA driver will do the IOVA mapping to IPA domain.
- TX/RX buffers need to be mapped to IPA domain by WLAN driver
via ipa_wdi_create|release_smmu_mapping API.
- IPA doorbell addresses returned from ipa_wdi_conn_pipes are
DDR addresses and WLAN driver needs to do the IOVA mapping
to WLAN domain.
Change-Id: I2398df58c9a9d002af7035f239eda37a86f5d00f
CRs-Fixed: 2422155
When IPA using GSI instead of UC different IPA TX and RX
clients needs to be configured. In this change when IPA
uses GSI configure appropriate TX and RX clients/pipes.
Change-Id: I0302323d91f0cc4256a1b08ddbb1345d0daa2939
CRs-Fixed: 2368003
To abstract kernel header inclusion, create a new QDF APIs for all IPA
APIs and redirect all IPA API calls through QDF interfaces.
Change-Id: I7bff975ad7cb32fc128320c124633594471e0a1f
CRs-Fixed: 2098907