qcacld-3.0: cdp: Converge cdp_ctrl_ops

Currently cdp ops are given pdev/vdev 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/vdev_id which will be used to get the
respective handles and hence avoiding unwanted
access of the handles if it has been deleted.

Also deleting few ops which stores and retrieves
such handles and adding ops to set/get pdev params.

- txrx_set_safemode
- txrx_set_drop_unenc
- txrx_get_pdev_param
- txrx_set_pdev_param
- wdi_event_sub
- wdi_event_unsub

Change-Id: Ib3511cbdead75b30e899dbf00f936ffdae316b71
CRs-Fixed: 2541657
This commit is contained in:
Vevek Venkatesan
2019-09-11 17:47:34 +05:30
zatwierdzone przez nshrivas
rodzic 70d980dd15
commit e9fa59de57
14 zmienionych plików z 187 dodań i 124 usunięć

Wyświetl plik

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2017-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -1187,9 +1187,9 @@ QDF_STATUS tdls_process_del_peer(struct tdls_oper_request *req)
if (soc_obj->tdls_dp_vdev_update)
soc_obj->tdls_dp_vdev_update(&soc_obj->soc,
&peer->peer_mac,
soc_obj->tdls_update_dp_vdev_flags,
false);
wlan_vdev_get_id(vdev),
soc_obj->tdls_update_dp_vdev_flags,
false);
cmd.cmd_type = WLAN_SER_CMD_TDLS_DEL_PEER;
cmd.cmd_id = 0;
@@ -1674,11 +1674,12 @@ QDF_STATUS tdls_process_enable_link(struct tdls_oper_request *req)
feature = soc_obj->tdls_configs.tdls_feature_flags;
if (soc_obj->tdls_dp_vdev_update)
soc_obj->tdls_dp_vdev_update(&soc_obj->soc,
&peer->peer_mac,
soc_obj->tdls_update_dp_vdev_flags,
((peer->link_status ==
TDLS_LINK_CONNECTED) ? true : false));
soc_obj->tdls_dp_vdev_update(
&soc_obj->soc,
wlan_vdev_get_id(vdev),
soc_obj->tdls_update_dp_vdev_flags,
((peer->link_status == TDLS_LINK_CONNECTED) ?
true : false));
tdls_debug("TDLS buffer sta: %d, uapsd_mask %d",
TDLS_IS_BUFFER_STA_ENABLED(feature),
@@ -1890,8 +1891,9 @@ QDF_STATUS tdls_process_remove_force_peer(struct tdls_oper_request *req)
TDLS_LINK_UNSPECIFIED);
if (soc_obj->tdls_dp_vdev_update)
soc_obj->tdls_dp_vdev_update(&soc_obj->soc,
&peer->peer_mac,
soc_obj->tdls_dp_vdev_update(
&soc_obj->soc,
wlan_vdev_get_id(vdev),
soc_obj->tdls_update_dp_vdev_flags,
false);

Wyświetl plik

@@ -531,8 +531,9 @@ void tdls_indicate_teardown(struct tdls_vdev_priv_obj *tdls_vdev,
tdls_notice("Teardown reason %d", reason);
if (tdls_soc->tdls_dp_vdev_update)
tdls_soc->tdls_dp_vdev_update(&tdls_soc->soc,
&curr_peer->peer_mac,
tdls_soc->tdls_dp_vdev_update(
&tdls_soc->soc,
wlan_vdev_get_id(tdls_vdev->vdev),
tdls_soc->tdls_update_dp_vdev_flags,
false);

Wyświetl plik

@@ -610,7 +610,7 @@ typedef QDF_STATUS
/* This callback is used to update datapath vdev flags */
typedef QDF_STATUS
(*tdls_dp_vdev_update_flags_callback)(void *cbk_data,
struct qdf_mac_addr *peer_mac,
uint8_t vdev_id,
uint32_t vdev_param,
bool is_link_up);