瀏覽代碼

qcacld-3.0: Process stop bss during the channel change

Stop bss request is dropped during the
channel change request and it is causing
IPA disconnect event not to sent to IPA
module.

Process stop bss during channel change
request so that IPA disconnect is sent
to IPA module.

Change-Id: I41bb3c0d5ba9f9e9b3a655b67d126ee34c777f4d
CRs-Fixed: 2134143
Sandeep Puligilla 7 年之前
父節點
當前提交
20aa0c714c
共有 4 個文件被更改,包括 12 次插入0 次删除
  1. 3 0
      core/sap/src/sap_api_link_cntl.c
  2. 7 0
      core/sap/src/sap_fsm.c
  3. 1 0
      core/sap/src/sap_internal.h
  4. 1 0
      core/sap/src/sap_module.c

+ 3 - 0
core/sap/src/sap_api_link_cntl.c

@@ -567,6 +567,7 @@ wlansap_roam_process_dfs_chansw_update(tHalHandle hHal,
 		  FL("sapdfs: from state eSAP_STARTED => eSAP_DISCONNECTING"));
 	/* SAP to be moved to DISCONNECTING state */
 	sap_ctx->sapsMachine = eSAP_DISCONNECTING;
+	sap_ctx->is_chan_change_inprogress = true;
 	/*
 	 * The associated stations have been informed to move to a different
 	 * channel. However, the AP may not always select the advertised channel
@@ -1088,6 +1089,8 @@ wlansap_roam_callback(void *ctx, struct csr_roam_info *csr_roam_info,
 	case eCSR_ROAM_SET_CHANNEL_RSP:
 		QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO_HIGH,
 			  FL("Received set channel response"));
+		/* SAP channel change request processing is completed */
+		sap_ctx->is_chan_change_inprogress = false;
 		break;
 	case eCSR_ROAM_CAC_COMPLETE_IND:
 		QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO_HIGH,

+ 7 - 0
core/sap/src/sap_fsm.c

@@ -3604,6 +3604,13 @@ static QDF_STATUS sap_fsm_state_disconnecting(struct sap_context *sap_ctx,
 			  "eSAP_DISCONNECTING ", msg, sap_event->u2);
 		if (sap_event->u2 == eCSR_ROAM_RESULT_CHANNEL_CHANGE_FAILURE)
 			qdf_status = sap_goto_disconnecting(sap_ctx);
+	} else if ((msg == eSAP_HDD_STOP_INFRA_BSS) &&
+			(sap_ctx->is_chan_change_inprogress)) {
+		/* stop bss is recieved while processing channel change */
+		QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO,
+			  FL("in state %s, event msg %d result %d"),
+			  "eSAP_DISCONNECTING ", msg, sap_event->u2);
+		sap_goto_disconnecting(sap_ctx);
 	} else {
 		QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_ERROR,
 			  FL("in state %s, invalid event msg %d"),

+ 1 - 0
core/sap/src/sap_internal.h

@@ -258,6 +258,7 @@ struct sap_context {
 	uint8_t sap_acs_pre_start_bss;
 	uint8_t sap_sta_id;
 	bool dfs_cac_offload;
+	bool is_chan_change_inprogress;
 };
 
 /*----------------------------------------------------------------------------

+ 1 - 0
core/sap/src/sap_module.c

@@ -685,6 +685,7 @@ QDF_STATUS wlansap_start_bss(struct sap_context *sap_ctx,
 	sap_ctx->acs_cfg = &pConfig->acs_cfg;
 	sap_ctx->dfs_cac_offload = pConfig->dfs_cac_offload;
 	sap_ctx->isCacEndNotified = false;
+	sap_ctx->is_chan_change_inprogress = false;
 	/* Set the BSSID to your "self MAC Addr" read the mac address
 		from Configuation ITEM received from HDD */
 	sap_ctx->csr_roamProfile.BSSIDs.numOfBSSIDs = 1;