Merge "qca-wifi: Use module_id while getting vdev reference"
diff --git a/dp/wifi3.0/dp_tx_capture.c b/dp/wifi3.0/dp_tx_capture.c
index f2af421..9946795 100644
--- a/dp/wifi3.0/dp_tx_capture.c
+++ b/dp/wifi3.0/dp_tx_capture.c
@@ -2676,12 +2676,14 @@
dp_peer_unref_delete(peer, DP_MOD_ID_TX_CAPTURE);
} else {
vdev =
- dp_vdev_get_ref_by_id(pdev->soc, ppdu_desc->vdev_id);
+ dp_vdev_get_ref_by_id(pdev->soc, ppdu_desc->vdev_id,
+ DP_MOD_ID_TX_CAPTURE);
if (vdev) {
qdf_mem_copy(wh_min->i_addr2,
vdev->mac_addr.raw,
QDF_MAC_ADDR_SIZE);
- dp_vdev_unref_delete(pdev->soc, vdev);
+ dp_vdev_unref_delete(pdev->soc, vdev,
+ DP_MOD_ID_TX_CAPTURE);
}
}
qdf_nbuf_set_pktlen(tx_capture_info.mpdu_nbuf, sizeof(*wh_min));
@@ -2792,12 +2794,14 @@
uint8_t vdev_id;
vdev_id = ppdu_desc->vdev_id;
- vdev = dp_vdev_get_ref_by_id(pdev->soc, vdev_id);
+ vdev = dp_vdev_get_ref_by_id(pdev->soc, vdev_id,
+ DP_MOD_ID_TX_CAPTURE);
if (vdev) {
qdf_mem_copy(&ppdu_desc->user[usr_id].mac_addr,
vdev->mac_addr.raw,
QDF_MAC_ADDR_SIZE);
- dp_vdev_unref_delete(pdev->soc, vdev);
+ dp_vdev_unref_delete(pdev->soc, vdev,
+ DP_MOD_ID_TX_CAPTURE);
}
}
diff --git a/dp/wifi3.0/dp_txrx_me.c b/dp/wifi3.0/dp_txrx_me.c
index 9eac78f..c8c2c9c 100644
--- a/dp/wifi3.0/dp_txrx_me.c
+++ b/dp/wifi3.0/dp_txrx_me.c
@@ -281,7 +281,8 @@
qdf_dma_addr_t paddr_mcbuf = 0;
uint8_t empty_entry_mac[QDF_MAC_ADDR_SIZE] = {0};
QDF_STATUS status;
- struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id);
+ struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id,
+ DP_MOD_ID_MCAST2UCAST);
if (!vdev)
goto free_return;
@@ -430,7 +431,7 @@
qdf_nbuf_unmap(pdev->soc->osdev, nbuf, QDF_DMA_TO_DEVICE);
qdf_nbuf_free(nbuf);
- dp_vdev_unref_delete(soc, vdev);
+ dp_vdev_unref_delete(soc, vdev, DP_MOD_ID_MCAST2UCAST);
return new_mac_cnt;
fail_map:
@@ -449,7 +450,7 @@
qdf_nbuf_unmap(pdev->soc->osdev, nbuf, QDF_DMA_TO_DEVICE);
free_return:
if (vdev)
- dp_vdev_unref_delete(soc, vdev);
+ dp_vdev_unref_delete(soc, vdev, DP_MOD_ID_MCAST2UCAST);
qdf_nbuf_free(nbuf);
return 1;
}
diff --git a/dp/wifi3.0/dp_txrx_wds.c b/dp/wifi3.0/dp_txrx_wds.c
index 1e4d292..f768523 100644
--- a/dp/wifi3.0/dp_txrx_wds.c
+++ b/dp/wifi3.0/dp_txrx_wds.c
@@ -233,7 +233,8 @@
{
struct dp_soc *soc = cdp_soc_t_to_dp_soc(soc_hdl);
struct dp_peer *peer;
- struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id);
+ struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id,
+ DP_MOD_ID_MISC);
if (!vdev) {
QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_ERROR,
FL("vdev is NULL for vdev_id %d"), vdev_id);
@@ -251,7 +252,7 @@
dp_peer_unref_delete(peer, DP_MOD_ID_AST);
}
- dp_vdev_unref_delete(soc, vdev);
+ dp_vdev_unref_delete(soc, vdev, DP_MOD_ID_MISC);
return QDF_STATUS_SUCCESS;
}
@@ -695,11 +696,12 @@
{
struct dp_soc *soc = (struct dp_soc *)cdp_soc;
struct dp_vdev *vdev =
- dp_vdev_get_ref_by_id((struct dp_soc *)soc, vdev_id);
+ dp_vdev_get_ref_by_id((struct dp_soc *)soc, vdev_id,
+ DP_MOD_ID_TX_MULTIPASS);
if (vdev && vdev->multipass_en) {
dp_peer_multipass_list_add(soc, peer_mac, vdev_id, vlan_id);
- dp_vdev_unref_delete(soc, vdev);
+ dp_vdev_unref_delete(soc, vdev, DP_MOD_ID_TX_MULTIPASS);
}
}
@@ -716,7 +718,8 @@
uint16_t vlan_id, uint16_t group_key)
{
struct dp_soc *soc = cdp_soc_t_to_dp_soc(soc_hdl);
- struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id);
+ struct dp_vdev *vdev = dp_vdev_get_ref_by_id(soc, vdev_id,
+ DP_MOD_ID_TX_MULTIPASS);
QDF_STATUS status;
if (!vdev || !vdev->multipass_en) {
@@ -750,7 +753,7 @@
status = QDF_STATUS_SUCCESS;
fail:
if (vdev)
- dp_vdev_unref_delete(soc, vdev);
+ dp_vdev_unref_delete(soc, vdev, DP_MOD_ID_TX_MULTIPASS);
return status;
}