qcacld-3.0: cdp: Convergence of cdp_l_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 l_flowctl_ops
- register_tx_flow_control
- set_vdev_tx_desc_limit
- set_vdev_os_queue_status
- deregister_tx_flow_control_cb
- flow_control_cb
- get_tx_resource
- ll_set_tx_pause_q_depth
- vdev_flush
- vdev_pause
- vdev_unpause

CRs-Fixed: 2539748
Change-Id: I8ad4a20914c654b8e8aaf629dda7f673fdb110e4
This commit is contained in:
Rakesh Pillai 2019-11-07 19:54:01 +05:30 • committed by nshrivas
commit f94b162ed0
15 changed files with 275 additions and 226 deletions

View file

@ -643,18 +643,13 @@ static void pmo_unpause_all_vdev(struct wlan_objmgr_psoc *psoc,
struct pmo_psoc_priv_obj *psoc_ctx)
{
uint8_t vdev_id;
struct cdp_vdev *vdev_dp;
/* Iterate through VDEV list */
for (vdev_id = 0; vdev_id < WLAN_UMAC_PSOC_MAX_VDEVS; vdev_id++) {
vdev_dp = pmo_core_vdev_get_dp_handle(psoc_ctx, vdev_id);
if (!vdev_dp)
continue;
/* When host resumes, by default unpause all active vdev */
if (pmo_core_vdev_get_pause_bitmap(psoc_ctx, vdev_id)) {
cdp_fc_vdev_unpause(pmo_core_psoc_get_dp_handle(psoc),
vdev_dp,
vdev_id,
0xffffffff, 0);
if (psoc_ctx->pause_bitmap_notifier)
psoc_ctx->pause_bitmap_notifier(vdev_id, 0);