Browse Source

qcacld-3.0: Report right auth failure status

When auth tx failure happens, lim_auth_tx_complete_cnf sets
stats for variable mac_ctx->auth_ack_status accordingly.
But lim_process_auth_retry_timer will reset that variable
to LIM_ACK_NOT_RCD. If auth retry has sent and tx complete
has not called back yet, then lim_process_auth_failure_timeout
happens, now since the variable auth_ack_status is not updated
again and driver reports wrong auth failure status to framework.

To resolve this issue, don't reset auth_ack_status when auth
retry sending.

Change-Id: I51c296cb6d8d7a145bba6b49d0b378cb9f6ff665
CRs-Fixed: 3400258
Paul Zhang 2 years ago
parent
commit
994f014c87

+ 1 - 1
core/mac/src/pe/lim/lim_process_mlm_req_messages.c

@@ -1843,7 +1843,6 @@ static void lim_process_auth_retry_timer(struct mac_context *mac_ctx)
 						SIR_MAC_AUTH_FRAME_1;
 			auth_frame->authStatusCode = 0;
 			pe_debug("Retry Auth");
-			mac_ctx->auth_ack_status = LIM_ACK_NOT_RCD;
 			lim_increase_fils_sequence_number(session_entry);
 			lim_send_auth_mgmt_frame(mac_ctx, auth_frame,
 				mac_ctx->lim.gpLimMlmAuthReq->peerMacAddr,
@@ -1924,6 +1923,7 @@ void lim_process_auth_failure_timeout(struct mac_context *mac_ctx)
 		lim_restore_from_auth_state(mac_ctx,
 				eSIR_SME_AUTH_TIMEOUT_RESULT_CODE,
 				proto_status_code, session);
+		mac_ctx->auth_ack_status = LIM_ACK_NOT_RCD;
 		break;
 	default:
 		/*

+ 3 - 1
core/mac/src/pe/lim/lim_send_management_frames.c

@@ -3801,7 +3801,9 @@ alloc_packet:
 	MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT,
 			 session->peSessionId, mac_hdr->fc.subType));
 
-	mac_ctx->auth_ack_status = LIM_ACK_NOT_RCD;
+	if (mac_ctx->auth_ack_status != LIM_ACK_RCD_FAILURE &&
+	    mac_ctx->auth_ack_status != LIM_TX_FAILED)
+		mac_ctx->auth_ack_status = LIM_ACK_NOT_RCD;
 	min_rid = lim_get_min_session_txrate(session, NULL);
 	peer_rssi = mac_ctx->lim.bss_rssi;
 	lim_diag_mgmt_tx_event_report(mac_ctx, mac_hdr,