Ver Fonte

qcacld-3.0: Do DEL_STA if driver gets deauth during ADD_STA

qcacld-2.0 to qcacld-3.0 propagation

Add new resultCode, 'eSIR_SME_JOIN_DEAUTH_FROM_AP_DURING_ADD_STA',
to make sure driver does DEL_STA follwed by DEL_BSS, if driver
receives DEAUTH frame when it's waiting for ADD_STA_RSP.

Change-Id: I697a8bf4e4f4d8b1063ad660395cea33031f1647
CRs-Fixed: 599416
Hanumantha Reddy Pothula há 8 anos atrás
pai
commit
6677a335ba
1 ficheiros alterados com 15 adições e 3 exclusões
  1. 15 3
      core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c

+ 15 - 3
core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c

@@ -691,9 +691,21 @@ void lim_process_mlm_assoc_cnf(tpAniSirGlobal mac_ctx,
 	}
 	if (((tLimMlmAssocCnf *) msg)->resultCode != eSIR_SME_SUCCESS) {
 		/* Association failure */
-		lim_log(mac_ctx, LOG1, FL("SessionId:%d Association failure"),
-			session_entry->peSessionId);
-		session_entry->limSmeState = eLIM_SME_JOIN_FAILURE_STATE;
+		lim_log(mac_ctx, LOG1, FL("SessionId:%d Association failure resultCode: %d limSmeState:%d"),
+			session_entry->peSessionId,
+			((tLimMlmAssocCnf *) msg)->resultCode,
+			session_entry->limSmeState);
+
+		/* If driver gets deauth when its waiting for ADD_STA_RSP then
+		 * we need to do DEL_STA followed by DEL_BSS. So based on below
+		 * reason-code here we decide whether to do only DEL_BSS or
+		 * DEL_STA + DEL_BSS.
+		 */
+		if (((tLimMlmAssocCnf *) msg)->resultCode !=
+		    eSIR_SME_JOIN_DEAUTH_FROM_AP_DURING_ADD_STA)
+			session_entry->limSmeState =
+				eLIM_SME_JOIN_FAILURE_STATE;
+
 		MTRACE(mac_trace(mac_ctx, TRACE_CODE_SME_STATE,
 			session_entry->peSessionId, mac_ctx->lim.gLimSmeState));
 		/*