From 90c95debe0cd1ccba28896fe52ff442500a38f32 Mon Sep 17 00:00:00 2001 From: Jeff Johnson Date: Thu, 31 Aug 2017 14:38:11 -0700 Subject: [PATCH] qcacld-3.0: Remove obsolete sys_stop() Function sys_stop() is no longer being used, so remove it. Change-Id: I107fab5a0d39a58521a39a9c6bf29a5728b7ccf2 CRs-Fixed: 2102668 --- core/mac/src/sys/common/inc/wlan_qct_sys.h | 19 ------ core/mac/src/sys/common/src/wlan_qct_sys.c | 68 ---------------------- 2 files changed, 87 deletions(-) diff --git a/core/mac/src/sys/common/inc/wlan_qct_sys.h b/core/mac/src/sys/common/inc/wlan_qct_sys.h index 5d9c4d04c1ce..d9d2b5f175e3 100644 --- a/core/mac/src/sys/common/inc/wlan_qct_sys.h +++ b/core/mac/src/sys/common/inc/wlan_qct_sys.h @@ -131,25 +131,6 @@ QDF_STATUS sys_build_message_header(SYS_MSG_ID sysMsgId, QDF_STATUS sysMcStart(v_CONTEXT_t p_cds_context, sysResponseCback userCallback, void *pUserData); -/*---------------------------------------------------------------------------- - - \brief sys_stop() - Stop the SYS module. - - This function stops the SYS module. - - \todo: What else do we need to do on sys_stop()? - - \param p_cds_context - pointer to the CDS Context - - \return QDF_STATUS_SUCCESS - the SYS module is stopped. - - QDF_STATUS_E_FAILURE - the SYS module open failed to stop. - - \sa - - --------------------------------------------------------------------------*/ -QDF_STATUS sys_stop(v_CONTEXT_t p_cds_context); - /*---------------------------------------------------------------------------- \brief sys_mc_process_msg() - process SYS messages on the Main Controller thread diff --git a/core/mac/src/sys/common/src/wlan_qct_sys.c b/core/mac/src/sys/common/src/wlan_qct_sys.c index f2e6bf4d7690..35d7a1997f93 100644 --- a/core/mac/src/sys/common/src/wlan_qct_sys.c +++ b/core/mac/src/sys/common/src/wlan_qct_sys.c @@ -37,10 +37,6 @@ #include "mac_init_api.h" #include "qdf_trace.h" -/* SYS stop timeout 30 seconds */ -#define SYS_STOP_TIMEOUT (30000) -static qdf_event_t g_stop_evt; - /** * sys_build_message_header() - to build the sys message header * @sysMsgId: message id @@ -59,70 +55,6 @@ QDF_STATUS sys_build_message_header(SYS_MSG_ID sysMsgId, return QDF_STATUS_SUCCESS; } -/** - * sys_stop_complete_cb() - a callback when system stop completes - * @pUserData: pointer to user provided data context - * - * this callback is used once system stop is completed. - * - * Return: none - */ -#ifdef QDF_ENABLE_TRACING -static void sys_stop_complete_cb(void *pUserData) -{ - qdf_event_t *pStopEvt = (qdf_event_t *) pUserData; - QDF_STATUS qdf_status = qdf_event_set(pStopEvt); - - QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status)); - -} -#else -static void sys_stop_complete_cb(void *pUserData) -{ - return; -} -#endif - -/** - * sys_stop() - To post stop message to system module - * @p_cds_context: pointer to cds context - * - * This API is used post a stop message to system module - * - * Return: QDF_STATUS - */ -QDF_STATUS sys_stop(v_CONTEXT_t p_cds_context) -{ - QDF_STATUS qdf_status = QDF_STATUS_SUCCESS; - struct scheduler_msg sysMsg = {0}; - - /* Initialize the stop event */ - qdf_status = qdf_event_create(&g_stop_evt); - - if (!QDF_IS_STATUS_SUCCESS(qdf_status)) - return qdf_status; - - /* post a message to SYS module in MC to stop SME and MAC */ - sys_build_message_header(SYS_MSG_ID_MC_STOP, &sysMsg); - - /* Save the user callback and user data */ - sysMsg.callback = sys_stop_complete_cb; - sysMsg.bodyptr = (void *)&g_stop_evt; - - /* post the message.. */ - qdf_status = scheduler_post_msg(QDF_MODULE_ID_SYS, &sysMsg); - if (!QDF_IS_STATUS_SUCCESS(qdf_status)) - qdf_status = QDF_STATUS_E_BADMSG; - - qdf_status = qdf_wait_single_event(&g_stop_evt, SYS_STOP_TIMEOUT); - QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status)); - - qdf_status = qdf_event_destroy(&g_stop_evt); - QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status)); - - return qdf_status; -} - /** * sys_mc_process_msg() - to process system mc thread messages * @p_cds_context: pointer to cds context