From 0358fd452a05d7dd39e0c4f0cc1a87cd95e3288f Mon Sep 17 00:00:00 2001 From: Jia Ding Date: Wed, 2 Sep 2020 19:51:19 +0800 Subject: [PATCH] qcacld-3.0: Provide soc handle and pdev id for IPA cleanup To do SMMU unmap for IPA TX and RX doorbell registers, provide soc handle and pdev id to CDP layer. Change-Id: I6e4fcc7d96d3dabe9dcbb85b9d7193e898d9a73e CRs-Fixed: 2768306 --- components/ipa/core/src/wlan_ipa_core.c | 1 + core/dp/txrx/ol_txrx_ipa.c | 12 ++++++++++-- core/dp/txrx/ol_txrx_ipa.h | 5 +++-- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/components/ipa/core/src/wlan_ipa_core.c b/components/ipa/core/src/wlan_ipa_core.c index 590cf2c8af70..d8ec3107fc04 100644 --- a/components/ipa/core/src/wlan_ipa_core.c +++ b/components/ipa/core/src/wlan_ipa_core.c @@ -3637,6 +3637,7 @@ QDF_STATUS wlan_ipa_uc_ol_deinit(struct wlan_ipa_priv *ipa_ctx) if (true == ipa_ctx->uc_loaded) { status = cdp_ipa_cleanup(ipa_ctx->dp_soc, + ipa_ctx->dp_pdev_id, ipa_ctx->tx_pipe_handle, ipa_ctx->rx_pipe_handle); if (status) diff --git a/core/dp/txrx/ol_txrx_ipa.c b/core/dp/txrx/ol_txrx_ipa.c index 876921d19926..2cb659d0d125 100644 --- a/core/dp/txrx/ol_txrx_ipa.c +++ b/core/dp/txrx/ol_txrx_ipa.c @@ -706,12 +706,16 @@ QDF_STATUS ol_txrx_ipa_setup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, /** * ol_txrx_ipa_cleanup() - Disconnect IPA pipes + * @soc_hdl: soc handle + * @pdev_id: pdev id * @tx_pipe_handle: Tx pipe handle * @rx_pipe_handle: Rx pipe handle * * Return: QDF_STATUS */ -QDF_STATUS ol_txrx_ipa_cleanup(uint32_t tx_pipe_handle, uint32_t rx_pipe_handle) +QDF_STATUS ol_txrx_ipa_cleanup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, + uint32_t tx_pipe_handle, + uint32_t rx_pipe_handle) { int ret; struct ol_txrx_ipa_resources *ipa_res; @@ -1210,12 +1214,16 @@ QDF_STATUS ol_txrx_ipa_setup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, /** * ol_txrx_ipa_cleanup() - Disconnect IPA pipes + * @soc_hdl: soc handle + * @pdev_id: pdev id * @tx_pipe_handle: Tx pipe handle * @rx_pipe_handle: Rx pipe handle * * Return: QDF_STATUS */ -QDF_STATUS ol_txrx_ipa_cleanup(uint32_t tx_pipe_handle, uint32_t rx_pipe_handle) +QDF_STATUS ol_txrx_ipa_cleanup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, + uint32_t tx_pipe_handle, + uint32_t rx_pipe_handle) { int ret; diff --git a/core/dp/txrx/ol_txrx_ipa.h b/core/dp/txrx/ol_txrx_ipa.h index 10892a83c993..be516906c521 100644 --- a/core/dp/txrx/ol_txrx_ipa.h +++ b/core/dp/txrx/ol_txrx_ipa.h @@ -261,8 +261,9 @@ QDF_STATUS ol_txrx_ipa_setup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, bool is_rm_enabled, uint32_t *tx_pipe_handle, uint32_t *rx_pipe_handle); #endif /* CONFIG_IPA_WDI_UNIFIED_API */ -QDF_STATUS ol_txrx_ipa_cleanup(uint32_t tx_pipe_handle, - uint32_t rx_pipe_handle); +QDF_STATUS ol_txrx_ipa_cleanup(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, + uint32_t tx_pipe_handle, + uint32_t rx_pipe_handle); QDF_STATUS ol_txrx_ipa_setup_iface(char *ifname, uint8_t *mac_addr, qdf_ipa_client_type_t prod_client, qdf_ipa_client_type_t cons_client,