From cc1f3f9ffd3c331dcbab9865d47e8583d12fd1cc Mon Sep 17 00:00:00 2001 From: Mukul Sharma Date: Mon, 30 Jan 2017 19:56:24 +0530 Subject: [PATCH] qcacld-3.0: Add WMI reference in PSOC and PSoc reference in WMI Add WMI reference in PSOC and PSoc reference in WMI. Change-Id: Ib5bb685039162fe84bac8ed6c98f848f8c7460b7 CRs-Fixed: 2002028 --- core/wma/src/wma_main.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/core/wma/src/wma_main.c b/core/wma/src/wma_main.c index 1e411bae5b6a..726a440cec85 100644 --- a/core/wma/src/wma_main.c +++ b/core/wma/src/wma_main.c @@ -1924,7 +1924,7 @@ QDF_STATUS wma_open(struct wlan_objmgr_psoc *psoc, void *cds_context, ops.wma_process_fw_event_handler_cbk = wma_process_fw_event_handler; /* attach the wmi */ wmi_handle = wmi_unified_attach(wma_handle, NULL, - WMI_TLV_TARGET, use_cookie, &ops); + WMI_TLV_TARGET, use_cookie, &ops, psoc); if (!wmi_handle) { WMA_LOGP("%s: failed to attach WMI", __func__); qdf_status = QDF_STATUS_E_NOMEM; @@ -1932,6 +1932,12 @@ QDF_STATUS wma_open(struct wlan_objmgr_psoc *psoc, void *cds_context, } WMA_LOGA("WMA --> wmi_unified_attach - success"); + + /* set the wmi handle (as tgt_if_handle) in psoc */ + wlan_psoc_obj_lock(psoc); + wlan_psoc_set_tgt_if_handle(psoc, wmi_handle); + wlan_psoc_obj_unlock(psoc); + wmi_unified_register_event_handler(wmi_handle, WMI_SERVICE_READY_EVENTID, wma_rx_service_ready_event,