qcacld-3.0: Use p2p osif dbg id for ref count operations
Change HDD layer to use WLAN_OSIF_P2P_ID reference count dbg id for vdev reference count acquire/release when process p2p request. Change-Id: I485ca13d37d3440b8aee75ced7fba75ff24efbd1 CRs-Fixed: 2813935
Esse commit está contido em:
@@ -93,13 +93,13 @@ void wlan_hdd_cancel_existing_remain_on_channel(struct hdd_adapter *adapter)
|
||||
return;
|
||||
}
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return;
|
||||
}
|
||||
ucfg_p2p_cleanup_roc_by_vdev(vdev);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
}
|
||||
|
||||
int wlan_hdd_check_remain_on_channel(struct hdd_adapter *adapter)
|
||||
@@ -120,14 +120,14 @@ void wlan_hdd_cleanup_remain_on_channel_ctx(struct hdd_adapter *adapter)
|
||||
return;
|
||||
}
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return;
|
||||
}
|
||||
|
||||
ucfg_p2p_cleanup_roc_by_vdev(vdev);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
}
|
||||
|
||||
void wlan_hdd_cleanup_actionframe(struct hdd_adapter *adapter)
|
||||
@@ -139,13 +139,13 @@ void wlan_hdd_cleanup_actionframe(struct hdd_adapter *adapter)
|
||||
return;
|
||||
}
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return;
|
||||
}
|
||||
ucfg_p2p_cleanup_tx_by_vdev(vdev);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
}
|
||||
|
||||
static int __wlan_hdd_cfg80211_remain_on_channel(struct wiphy *wiphy,
|
||||
@@ -176,7 +176,7 @@ static int __wlan_hdd_cfg80211_remain_on_channel(struct wiphy *wiphy,
|
||||
if (wlan_hdd_validate_vdev_id(adapter->vdev_id))
|
||||
return -EINVAL;
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return -EINVAL;
|
||||
@@ -186,7 +186,7 @@ static int __wlan_hdd_cfg80211_remain_on_channel(struct wiphy *wiphy,
|
||||
ucfg_nan_disable_concurrency(hdd_ctx->psoc);
|
||||
|
||||
status = wlan_cfg80211_roc(vdev, chan, duration, cookie);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
hdd_debug("remain on channel request, status:%d, cookie:0x%llx",
|
||||
status, *cookie);
|
||||
|
||||
@@ -233,14 +233,14 @@ __wlan_hdd_cfg80211_cancel_remain_on_channel(struct wiphy *wiphy,
|
||||
if (wlan_hdd_validate_vdev_id(adapter->vdev_id))
|
||||
return -EINVAL;
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
status = wlan_cfg80211_cancel_roc(vdev, cookie);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
|
||||
hdd_debug("cancel remain on channel, status:%d", status);
|
||||
|
||||
@@ -357,7 +357,7 @@ static int __wlan_hdd_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev,
|
||||
|
||||
wlan_hdd_validate_and_override_offchan(adapter, chan, &offchan);
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return -EINVAL;
|
||||
@@ -369,7 +369,7 @@ static int __wlan_hdd_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev,
|
||||
|
||||
status = wlan_cfg80211_mgmt_tx(vdev, chan, offchan, wait, buf,
|
||||
len, no_cck, dont_wait_for_ack, cookie);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
hdd_debug("mgmt tx, status:%d, cookie:0x%llx", status, *cookie);
|
||||
|
||||
return 0;
|
||||
@@ -428,14 +428,14 @@ static int __wlan_hdd_cfg80211_mgmt_tx_cancel_wait(struct wiphy *wiphy,
|
||||
if (wlan_hdd_validate_vdev_id(adapter->vdev_id))
|
||||
return -EINVAL;
|
||||
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (!vdev) {
|
||||
hdd_err("vdev is NULL");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
status = wlan_cfg80211_mgmt_tx_cancel(vdev, cookie);
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
|
||||
hdd_debug("cancel mgmt tx, status:%d", status);
|
||||
|
||||
@@ -735,7 +735,7 @@ struct wireless_dev *__wlan_hdd_add_virtual_intf(struct wiphy *wiphy,
|
||||
|
||||
adapter = hdd_get_adapter(hdd_ctx, QDF_STA_MODE);
|
||||
if (adapter && !wlan_hdd_validate_vdev_id(adapter->vdev_id)) {
|
||||
vdev = hdd_objmgr_get_vdev(adapter);
|
||||
vdev = hdd_objmgr_get_vdev_by_user(adapter, WLAN_OSIF_P2P_ID);
|
||||
if (vdev) {
|
||||
if (ucfg_scan_get_vdev_status(vdev) !=
|
||||
SCAN_NOT_IN_PROGRESS) {
|
||||
@@ -743,7 +743,7 @@ struct wireless_dev *__wlan_hdd_add_virtual_intf(struct wiphy *wiphy,
|
||||
adapter->vdev_id,
|
||||
INVALID_SCAN_ID, false);
|
||||
}
|
||||
hdd_objmgr_put_vdev(vdev);
|
||||
hdd_objmgr_put_vdev_by_user(vdev, WLAN_OSIF_P2P_ID);
|
||||
} else {
|
||||
hdd_err("vdev is NULL");
|
||||
}
|
||||
|
Referência em uma nova issue
Block a user