qcacld-3.0: Remove cds_context param to cds_pre_enable()
Currently cds_pre_enable() takes a cds_context param. However CDS already maintains its own context, hence this param introduces an unnecessary coupling, so remove it. Change-Id: I5a33859583ea4245c79daf42addd62ecedfd11df CRs-Fixed: 2109242
This commit is contained in:

gecommit door
snandini

bovenliggende
52e0c4384e
commit
3a28012805
@@ -309,7 +309,7 @@ static inline bool cds_is_driver_loaded(void)
|
||||
v_CONTEXT_t cds_init(void);
|
||||
void cds_deinit(void);
|
||||
|
||||
QDF_STATUS cds_pre_enable(v_CONTEXT_t cds_context);
|
||||
QDF_STATUS cds_pre_enable(void);
|
||||
|
||||
QDF_STATUS cds_open(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
|
@@ -684,33 +684,32 @@ err_probe_event:
|
||||
|
||||
/**
|
||||
* cds_pre_enable() - pre enable cds
|
||||
* @cds_context: CDS context
|
||||
*
|
||||
* Return: QDF status
|
||||
*/
|
||||
QDF_STATUS cds_pre_enable(v_CONTEXT_t cds_context)
|
||||
QDF_STATUS cds_pre_enable(void)
|
||||
{
|
||||
QDF_STATUS qdf_status = QDF_STATUS_SUCCESS;
|
||||
p_cds_contextType p_cds_context = (p_cds_contextType) cds_context;
|
||||
void *scn;
|
||||
void *soc = cds_get_context(QDF_MODULE_ID_SOC);
|
||||
void *soc;
|
||||
|
||||
QDF_TRACE(QDF_MODULE_ID_SYS, QDF_TRACE_LEVEL_DEBUG, "cds prestart");
|
||||
if (gp_cds_context != p_cds_context) {
|
||||
|
||||
if (!gp_cds_context) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_ERROR,
|
||||
"%s: Context mismatch", __func__);
|
||||
"%s: NULL CDS context", __func__);
|
||||
QDF_ASSERT(0);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
if (p_cds_context->pMACContext == NULL) {
|
||||
if (gp_cds_context->pMACContext == NULL) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_ERROR,
|
||||
"%s: MAC NULL context", __func__);
|
||||
QDF_ASSERT(0);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
if (p_cds_context->pWMAContext == NULL) {
|
||||
if (gp_cds_context->pWMAContext == NULL) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_ERROR,
|
||||
"%s: WMA NULL context", __func__);
|
||||
QDF_ASSERT(0);
|
||||
@@ -724,6 +723,13 @@ QDF_STATUS cds_pre_enable(v_CONTEXT_t cds_context)
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
soc = cds_get_context(QDF_MODULE_ID_SOC);
|
||||
if (!soc) {
|
||||
QDF_TRACE(QDF_MODULE_ID_QDF, QDF_TRACE_LEVEL_FATAL,
|
||||
"%s: soc is null!", __func__);
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
/* call Packetlog connect service */
|
||||
if (QDF_GLOBAL_FTM_MODE != cds_get_conparam() &&
|
||||
QDF_GLOBAL_EPPING_MODE != cds_get_conparam())
|
||||
|
@@ -2249,7 +2249,7 @@ int hdd_wlan_start_modules(struct hdd_context *hdd_ctx, struct hdd_adapter *adap
|
||||
|
||||
hdd_ctx->hHal = cds_get_context(QDF_MODULE_ID_SME);
|
||||
|
||||
status = cds_pre_enable(hdd_ctx->pcds_context);
|
||||
status = cds_pre_enable();
|
||||
if (!QDF_IS_STATUS_SUCCESS(status)) {
|
||||
hdd_err("Failed to pre-enable CDS: %d", status);
|
||||
goto close;
|
||||
|
Verwijs in nieuw issue
Block a user