qcacld-3.0: Remove tHalStopType

There are multiple places where a tHalStopType parameter is passed but
unused. This is a historical artifact, so remove all instances of it.

Change-Id: Iebcbbac580495a376b7456b3a2901f33c2474f83
CRs-Fixed: 2283460
This commit is contained in:
Jeff Johnson 2018-07-20 12:38:25 -07:00 • committed by nshrivas
commit 62cd6803a7
11 changed files with 64 additions and 67 deletions

View file

@ -930,14 +930,14 @@ err_soc_target_detach:
/* NOOP */
err_sme_stop:
sme_stop(gp_cds_context->mac_context, HAL_STOP_TYPE_SYS_RESET);
sme_stop(gp_cds_context->mac_context);
err_mac_stop:
mac_stop(gp_cds_context->mac_context, HAL_STOP_TYPE_SYS_RESET);
mac_stop(gp_cds_context->mac_context);
err_wma_stop:
qdf_event_reset(&gp_cds_context->wma_complete_event);
qdf_status = wma_stop(HAL_STOP_TYPE_RF_KILL);
qdf_status = wma_stop();
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
cds_err("Failed to stop wma");
QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
@ -984,7 +984,7 @@ QDF_STATUS cds_disable(struct wlan_objmgr_psoc *psoc)
dispatcher_psoc_disable(psoc);
}
qdf_status = wma_stop(HAL_STOP_TYPE_RF_KILL);
qdf_status = wma_stop();
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
cds_err("Failed to stop wma");

View file

@ -33,7 +33,21 @@
#include "sir_types.h"
QDF_STATUS mac_start(tHalHandle hHal, void *pHalMacStartParams);
QDF_STATUS mac_stop(tHalHandle hHal, tHalStopType stopType);
/**
* mac_stop() - Stop all MAC modules
* @mac_handle: Opaque handle to the MAC context
*
* This function is called to stop MAC. This function will stop all
* the mac modules.
*
* Return: QDF_STATUS_SUCCESS if the MAC was successfully stopped. Any
* other value means that there was an issue with stopping the
* MAC, but the caller should still consider the MAC to be
* stopped.
*/
QDF_STATUS mac_stop(mac_handle_t mac_handle);
QDF_STATUS mac_open(struct wlan_objmgr_psoc *psoc, tHalHandle *pHalHandle,
hdd_handle_t hdd_handle, struct cds_config_info *cds_cfg);
QDF_STATUS mac_close(tHalHandle hHal);

View file

@ -71,12 +71,6 @@ typedef mac_handle_t tHalHandle;
struct opaque_hdd_handle;
typedef struct opaque_hdd_handle *hdd_handle_t;
typedef enum {
HAL_STOP_TYPE_SYS_RESET,
HAL_STOP_TYPE_SYS_DEEP_SLEEP,
HAL_STOP_TYPE_RF_KILL,
} tHalStopType;
#define HAL_NUM_ASSOC_STA 32
#define HAL_NUM_STA 41

View file

@ -163,11 +163,9 @@ static QDF_STATUS sys_mc_process_msg(struct scheduler_msg *pMsg)
"%s: Invalid hHal", __func__);
break;
}
qdf_status = sme_stop(hHal,
HAL_STOP_TYPE_SYS_DEEP_SLEEP);
qdf_status = sme_stop(hHal);
QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
qdf_status = mac_stop(hHal,
HAL_STOP_TYPE_SYS_DEEP_SLEEP);
qdf_status = mac_stop(hHal);
QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
((sys_rsp_cb) pMsg->callback)(pMsg->bodyptr);
qdf_status = QDF_STATUS_SUCCESS;

View file

@ -62,21 +62,12 @@ QDF_STATUS mac_start(tHalHandle hHal, void *pHalMacStartParams)
return status;
}
/** -------------------------------------------------------------
\fn mac_stop
\brief this function will be called from HDD to stop MAC. This function will stop all the mac modules.
\ memory with global context will only be initialized not freed here.
\param tHalHandle hHal
\param tHalStopType
\return QDF_STATUS
-------------------------------------------------------------*/
QDF_STATUS mac_stop(tHalHandle hHal, tHalStopType stopType)
QDF_STATUS mac_stop(mac_handle_t mac_handle)
{
tpAniSirGlobal pMac = (tpAniSirGlobal) hHal;
tpAniSirGlobal mac = MAC_CONTEXT(mac_handle);
pe_stop(pMac);
cfg_cleanup(pMac);
pe_stop(mac);
cfg_cleanup(mac);
return QDF_STATUS_SUCCESS;
}

View file

@ -1223,7 +1223,7 @@ QDF_STATUS csr_open(tpAniSirGlobal pMac);
QDF_STATUS csr_init_chan_list(tpAniSirGlobal mac, uint8_t *alpha2);
QDF_STATUS csr_close(tpAniSirGlobal pMac);
QDF_STATUS csr_start(tpAniSirGlobal pMac);
QDF_STATUS csr_stop(tpAniSirGlobal pMac, tHalStopType stopType);
QDF_STATUS csr_stop(tpAniSirGlobal pMac);
QDF_STATUS csr_ready(tpAniSirGlobal pMac);
#ifdef FEATURE_WLAN_WAPI

View file

@ -288,7 +288,22 @@ QDF_STATUS sme_init_chan_list(tHalHandle hal, uint8_t *alpha2,
enum country_src cc_src);
QDF_STATUS sme_close(tHalHandle hHal);
QDF_STATUS sme_start(tHalHandle hHal);
QDF_STATUS sme_stop(tHalHandle hHal, tHalStopType stopType);
/**
* sme_stop() - Stop all SME modules and put them at idle state
* @mac_handle: Opaque handle to the MAC context
*
* The function stops each module in SME. Upon return, all modules are
* at idle state ready to start.
*
* This is a synchronous call
*
* Return: QDF_STATUS_SUCCESS if SME is stopped. Other status means
* SME failed to stop one or more modules but caller should
* still consider SME is stopped.
*/
QDF_STATUS sme_stop(mac_handle_t mac_handle);
/*
* sme_open_session() - Open a session for given persona
*

View file

@ -2446,42 +2446,27 @@ static QDF_STATUS sme_process_nss_update_resp(tpAniSirGlobal mac, uint8_t *msg)
return QDF_STATUS_SUCCESS;
}
/*
* sme_stop() - Stop all SME modules and put them at idle state
*
* The function stops each module in SME, PMC, CSR, etc. . Upon
* return, all modules are at idle state ready to start.
* This is a synchronous call
*
* hHal - The handle returned by mac_open
* tHalStopType - reason for stopping
* Return QDF_STATUS_SUCCESS - SME is stopped.
* Other status means SME is failed to stop but caller should still
* consider SME is stopped.
*/
QDF_STATUS sme_stop(tHalHandle hHal, tHalStopType stopType)
QDF_STATUS sme_stop(mac_handle_t mac_handle)
{
QDF_STATUS status = QDF_STATUS_E_FAILURE;
QDF_STATUS fail_status = QDF_STATUS_SUCCESS;
tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
QDF_STATUS status;
QDF_STATUS ret_status = QDF_STATUS_SUCCESS;
tpAniSirGlobal mac = MAC_CONTEXT(mac_handle);
status = rrm_stop(pMac);
if (!QDF_IS_STATUS_SUCCESS(status)) {
status = rrm_stop(mac);
if (QDF_IS_STATUS_ERROR(status)) {
ret_status = status;
sme_err("rrm_stop failed with status: %d", status);
}
status = csr_stop(pMac, stopType);
if (!QDF_IS_STATUS_SUCCESS(status)) {
status = csr_stop(mac);
if (QDF_IS_STATUS_ERROR(status)) {
ret_status = status;
sme_err("csr_stop failed with status: %d", status);
fail_status = status;
}
if (!QDF_IS_STATUS_SUCCESS(fail_status))
status = fail_status;
mac->sme.state = SME_STATE_STOP;
pMac->sme.state = SME_STATE_STOP;
return status;
return ret_status;
}
/*

View file

@ -1211,7 +1211,7 @@ QDF_STATUS csr_start(tpAniSirGlobal pMac)
return status;
}
QDF_STATUS csr_stop(tpAniSirGlobal pMac, tHalStopType stopType)
QDF_STATUS csr_stop(tpAniSirGlobal pMac)
{
uint32_t sessionId;

View file

@ -102,7 +102,14 @@ QDF_STATUS wma_mc_process_handler(struct scheduler_msg *msg);
QDF_STATUS wma_start(void);
QDF_STATUS wma_stop(uint8_t reason);
/**
* wma_stop() - wma stop function.
*
* Performs all of the operations required to stop the WMA layer
*
* Return: QDF_STATUS_SUCCESS on success, QDF Error on failure
*/
QDF_STATUS wma_stop(void);
QDF_STATUS wma_close(void);

View file

@ -4388,14 +4388,7 @@ end:
return qdf_status;
}
/**
* wma_stop() - wma stop function.
* cleanup timers and suspend target.
* @reason: reason for wma_stop.
*
* Return: 0 on success, QDF Error on failure
*/
QDF_STATUS wma_stop(uint8_t reason)
QDF_STATUS wma_stop(void)
{
tp_wma_handle wma_handle;
QDF_STATUS qdf_status = QDF_STATUS_SUCCESS;