qcacld-3.0: Take vdev ref only if vdev is not NULL
In functions ucfg_tdls_update_rx_pkt_cnt and ucfg_tdls_update_tx_pkt_cnt, driver tries to get the vdev ref, even if it is NULL. This can result in assert. Change-Id: I62b3a9b088324e06518e82203092a2ac9098ac13 CRs-Fixed: 2412095
This commit is contained in:

gecommit door
nshrivas

bovenliggende
9f11b0153b
commit
7f0e18d00d
@@ -933,26 +933,14 @@ void ucfg_tdls_update_rx_pkt_cnt(struct wlan_objmgr_vdev *vdev,
|
||||
struct qdf_mac_addr *mac_addr,
|
||||
struct qdf_mac_addr *dest_mac_addr)
|
||||
{
|
||||
QDF_STATUS status;
|
||||
status = wlan_objmgr_vdev_try_get_ref(vdev, WLAN_TDLS_NB_ID);
|
||||
if (status != QDF_STATUS_SUCCESS)
|
||||
return;
|
||||
tdls_update_rx_pkt_cnt(vdev, mac_addr, dest_mac_addr);
|
||||
|
||||
wlan_objmgr_vdev_release_ref(vdev, WLAN_TDLS_NB_ID);
|
||||
}
|
||||
|
||||
void ucfg_tdls_update_tx_pkt_cnt(struct wlan_objmgr_vdev *vdev,
|
||||
struct qdf_mac_addr *mac_addr)
|
||||
{
|
||||
QDF_STATUS status;
|
||||
status = wlan_objmgr_vdev_try_get_ref(vdev, WLAN_TDLS_NB_ID);
|
||||
if (status != QDF_STATUS_SUCCESS)
|
||||
return;
|
||||
tdls_update_tx_pkt_cnt(vdev, mac_addr);
|
||||
|
||||
wlan_objmgr_vdev_release_ref(vdev, WLAN_TDLS_NB_ID);
|
||||
|
||||
}
|
||||
|
||||
QDF_STATUS ucfg_tdls_antenna_switch(struct wlan_objmgr_vdev *vdev,
|
||||
|
Verwijs in nieuw issue
Block a user