Commit Graph

19 次程式碼提交

作者 SHA1 備註 提交日期
Chaithanya Garrepalli
ddc9e59e8f qcacmn: Add VDEV refcount debug support
Add debug support for VDEV refcount to take
refcount by module id and decrement corresponding
refcount with same module id

Change-Id: I15c075816994ba70155fefbc0bce208b20fb9a59
2020-08-20 10:07:32 -07:00
Chaithanya Garrepalli
a718007f03 qcacmn: increment vdev refcount for search by id
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
2020-08-20 10:07:28 -07:00
Jinwei Chen
05bd796311 qcacmn: fix invalid TX pool status when pool reattach
For AC based TX flow control, when try to do TX desc pool
reattach, currently even if TX desc pool avail_desc count
> BE_BK start threshold, it still mark pool status as
FLOW_POOL_ACTIVE_PAUSED.

Set correct pool status to FLOW_POOL_ACTIVE_UNPAUSED.

Change-Id: I6b675ffd71a2233ac23efbd6df2c235313f59cba
CRs-Fixed: 2687728
2020-05-19 22:29:20 -07:00
Yeshwanth Sriram Guntuka
6159db7efa qcacmn: Reset tx desc as part of flow pool delete
Tx desc flow pool for the vdev is not deleted as part
of disconnection due to tx_desc pending to be processed
in tx comp ring. Hdd_stop is triggered immediately after
this causing dp vdev detach. In parallel, the tx desc
from the tx comp ring is processed, wherein stale vdev
address is derefernced to get dp soc causing page fault.

Fix is to reset tx desc by setting the vdev to NULL as
part of dp_tx_delete_flow_pool and also reset count to
zero in dp_tx_comp_handler before ring desc process loop.

Change-Id: I66f718668ba84f89106d09e624d9593f89479e55
CRs-Fixed: 2683874
2020-05-15 00:36:54 -07:00
phadiman
1f3652debc qcacmn: Datapath init-deinit changes
Do a logical split of dp_soc_attach and
dp_pdev_attach into Allocation and initialization
and dp_soc_detach and dp_pdev_detach into
de-initialization and free routines

Change-Id: I23bdca0ca86db42a4d0b2554cd60d99bb207a647
2020-05-02 21:59:42 -07:00
Manjunathappa Prakash
25390a01c2 qcacmn: flow_ctrl_v2: decouple tx_desc from TCLring descs
Decouple software tx_descs from TCLring descriptors and Increase
TCLring descriptors max INI config limit to 2k to 32k.

Change-Id: I18d014cdb0c1e26b7661ff65aaa8dffe791d7163
CRs-Fixed: 2657056
2020-04-07 03:01:29 -07:00
Rakesh Pillai
dce01374cd qcacmn: cdp: Convergence of cdp_flowctl_ops
Currently the cdp apis 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/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.

Converged flowctl_ops
- flow_pool_map_handler
- flow_pool_unmap_handler
- dump_flow_pool_info
- tx_desc_thresh_reached

CRs-Fixed: 2539812
Change-Id: I084d3878df84778622340e87bddf90acd3e669d6
2019-11-11 23:08:22 -08:00
Sravan Kumar Kairam
220755895d qcacmn: Free tx desc pool at dp flow control deinit
Currently if tx flow control is enabled allocated tx desc pools
are deleted only in tx flow pool unmap handler from control path.
So cases in which control path unable to handle pool unmap handler
leads to tx desc pool resources memory leak. To handle this free
allocated all tx desc pool resources as part of dp flow control
deinit which is done as part of soc tx detach.

Change-Id: Ib750c2ce39baf7fc5aae5f0c8cb62bc848d2f864
CRs-Fixed: 2511515
2019-10-02 02:48:25 -07:00
Varun Reddy Yeturu
83a31a34b0 qcacmn: Add debug log in dp_tx_delete_flow_pool
Add debug log in dp_tx_delete_flow_pool() to know if
all available tx descriptors have been released to the
pool or not

Change-Id: Id0684effd5c5c0b531bb2d4b3f08d929aaa85b5c
CRs-Fixed: 2463632
2019-06-12 17:46:01 -07:00
Jeff Johnson
a8edf330f0 qcacmn: dp: Replace explicit comparison to NULL
Per the Linux Kernel coding style, as enforced by the kernel
checkpatch script, pointers should not be explicitly compared to
NULL. Therefore within dp replace any such comparisons with logical
operations performed on the pointer itself.

Change-Id: I61f3adab1208682d36235421f44a048e35df346d
CRs-Fixed: 2418258
2019-03-27 06:10:00 -07:00
chenguo
f44ac20b0c qcacmn: AC based TX flow control
Implement per access category flow control. Make sure lower AC
traffic, such as BE, will not starve higher AC, such as VI and VO,
traffic inside a single vdev.

This change is part of FR49094

Change-Id: I6aa15832eb48e8f3ada00eb29a7bc00999edaafd
CRs-Fixed: 2304436
2018-10-02 15:37:17 -07:00
jiad
331eb9e6f7 qcacmn: Fix DP flow pool map for non-LFR3 roaming
tx_desc allocation failures are observed when running roaming scenarios
on Napier x86, where roaming offload is disabled (non-LFR3) and during
roaming reassociation is sent by DUT. With Lithium_DP, tx_desc are
pre-allocated within flow pool and flow pool map and unmap are currently
hooked in policy manager when connection table is updated.

In roaming scenario, flow pool is created when STA is associated with old
AP. But new flow pool is not created but is reused with old AP since same
flow pool id is passed from protocol stack. When old AP is removed from
policy manager connection table, flow pool is thus unmapped which leads to
EAPOL packets transmit failure due to unavailability of tx desc.

Fix is to increate pool_create_cnt to avoid flow pool being unmapped.

Change-Id: Ia912c1d7fe8319bece00869a9a47c8a760b17e2f
CRs-Fixed: 2287284
2018-08-14 20:02:32 -07:00
Aditya Sathish
ded018e406 qcacmn: Clean up dp component prints
Clean up datapath component prints by correcting trace levels for
regularly occurring prints and removing newlines from converged
print APIs since qdf_trace_msh appends them by default.

Change-Id: Ie8fe319fcb737720f7400a165e134b6a18bd15b5
CRs-Fixed: 2243843
2018-08-10 18:11:21 -07:00
Manjunathappa Prakash
e6aba4f65f qcacmn: Add DP callbacks for flow_pool create and delete
Current lithim_dp flow pool created in wma_vdev_start, wma_vdev_start
is called for same vdev multiple times for vdev. This leads to creation
of multiple flow pools for each vdev. Instead create from policy_manager
when session become active.

Register flow pool create/delete callbacks with policy manager.
So that lithium_dp vdev flow pools are created/deleted when vdev
become active/not-active.

Change-Id: Iaf6aaece47c79c7e6f7745feaee35a6bc5cd1297
CRs-Fixed: 2231601
2018-06-06 05:49:26 -07:00
Jeff Johnson
e71b8c4019 qcacmn: dp: Remove legacy markings
Per current guidance remove legacy markings.

Change-Id: Id6b2e4758232355b0c47bf8c2f1a0b2a1eacba05
CRs-Fixed: 2230684
2018-05-18 02:17:24 -07:00
Manjunathappa Prakash
612594a523 qcacmn: Do not mark pool id as INVALID_FLOW_ID in unmap
In flow control V2, dp_tx_flow_pool_vdev_unmap marks flow_pool_id as
INVALID_FLOW_ID. To free descriptors inside pool dp_tx_desc_pool_free
uses flow_pool_id to get hold of pool.

Change-Id: I892052055b34638a1ba876fac6bfcd2ae3b0d5b3
CRs-Fixed: 2228943
2018-05-02 08:30:20 -07:00
Manjunathappa Prakash
38205cc1b7 qcacmn: Create flow control pools on vdev start
As many as 5 vdevs can be created, which is defined by MAX_SME_SESSIONS.
But flow control pools are only valid for active TxRx capable vdevs.
which is 3 active vdevs. So attach flow pool creation to vdev_start
instead of vdev_attach.

Change-Id: I137676ba618aa3a6684c7d17ef7d9263c4df6efe
CRs-Fixed: 2220079
2018-04-17 13:17:49 -07:00
Paul Zhang
66698093e1 qcacmn: fix spinlock paring issue
spin_lock/spin_unlock is not pairing.

Change-Id: Ib2cb73f542deee8bf4217daa731af49d07eaf7be
CRs-Fixed: 2105081
2017-11-01 13:17:26 -07:00
Manjunathappa Prakash
ced7ea6cf2 qcacmn: Add changes for Napier flow control
Adds support for flow control on convergence branch.
Allocate Tx descriptors dynamically when vdev comes up.
Tx queue is paused and unpaused internally in host based on the
stop and start thresholds.
Changes are added under compilation flag QCA_LL_TX_FLOW_CONTROL_V2.

Change-Id: I0ccb80b0099f39efad52ccd7d47f2709fdee2a93
CRs-Fixed: 2040457
2017-07-18 23:35:05 -07:00