qcacld-3.0: Remove cds_context param to cds_close()
Currently cds_close() takes a cds_context param. However CDS already maintains its own context, hence this param introduces an unnecessary coupling, so remove it. Change-Id: I9c5231ef5d1e2ca969ff01c3fa0dc9b202e1aabd CRs-Fixed: 2109430
This commit is contained in:
@@ -319,7 +319,7 @@ QDF_STATUS cds_disable(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
QDF_STATUS cds_post_disable(void);
|
||||
|
||||
QDF_STATUS cds_close(struct wlan_objmgr_psoc *psoc, v_CONTEXT_t cds_context);
|
||||
QDF_STATUS cds_close(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
void *cds_get_context(QDF_MODULE_ID moduleId);
|
||||
|
||||
|
@@ -1061,14 +1061,13 @@ QDF_STATUS cds_post_disable(void)
|
||||
/**
|
||||
* cds_close() - close cds module
|
||||
* @psoc: Psoc pointer
|
||||
* @cds_context: CDS context
|
||||
*
|
||||
* This API allows user to close modules registered
|
||||
* with connectivity device services.
|
||||
*
|
||||
* Return: QDF status
|
||||
*/
|
||||
QDF_STATUS cds_close(struct wlan_objmgr_psoc *psoc, v_CONTEXT_t cds_context)
|
||||
QDF_STATUS cds_close(struct wlan_objmgr_psoc *psoc)
|
||||
{
|
||||
QDF_STATUS qdf_status;
|
||||
void *ctx;
|
||||
@@ -1095,21 +1094,21 @@ QDF_STATUS cds_close(struct wlan_objmgr_psoc *psoc, v_CONTEXT_t cds_context)
|
||||
cdp_pdev_detach(cds_get_context(QDF_MODULE_ID_SOC),
|
||||
(struct cdp_pdev *)ctx, 1);
|
||||
|
||||
qdf_status = sme_close(((p_cds_contextType) cds_context)->pMACContext);
|
||||
qdf_status = sme_close(gp_cds_context->pMACContext);
|
||||
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_ERROR,
|
||||
"%s: Failed to close SME", __func__);
|
||||
QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
|
||||
}
|
||||
|
||||
qdf_status = mac_close(((p_cds_contextType) cds_context)->pMACContext);
|
||||
qdf_status = mac_close(gp_cds_context->pMACContext);
|
||||
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_ERROR,
|
||||
"%s: Failed to close MAC", __func__);
|
||||
QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
|
||||
}
|
||||
|
||||
((p_cds_contextType) cds_context)->pMACContext = NULL;
|
||||
gp_cds_context->pMACContext = NULL;
|
||||
|
||||
cdp_soc_detach(gp_cds_context->dp_soc);
|
||||
pmo_ucfg_psoc_update_dp_handle(psoc, NULL);
|
||||
|
@@ -2314,7 +2314,7 @@ post_disable:
|
||||
|
||||
close:
|
||||
hdd_ctx->driver_status = DRIVER_MODULES_CLOSED;
|
||||
cds_close(hdd_ctx->hdd_psoc, p_cds_context);
|
||||
cds_close(hdd_ctx->hdd_psoc);
|
||||
|
||||
ol_cds_free:
|
||||
ol_cds_free();
|
||||
@@ -9390,7 +9390,7 @@ int hdd_wlan_stop_modules(struct hdd_context *hdd_ctx, bool ftm_mode)
|
||||
ret = -EINVAL;
|
||||
QDF_ASSERT(0);
|
||||
}
|
||||
qdf_status = cds_close(hdd_ctx->hdd_psoc, hdd_ctx->pcds_context);
|
||||
qdf_status = cds_close(hdd_ctx->hdd_psoc);
|
||||
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
|
||||
hdd_warn("Failed to stop CDS: %d", qdf_status);
|
||||
ret = -EINVAL;
|
||||
|
Reference in New Issue
Block a user