summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPadma, Santhosh Kumar <skpadma@codeaurora.org>2016-08-08 18:10:14 +0530
committerNishank Aggarwal <naggar@codeaurora.org>2016-09-16 21:06:36 +0530
commitdcba34f1c149f5262125335395a9e0166dfafd0b (patch)
treea79fa6e7b9fe400735a1be49657a8839ea611876
parentdc038ee71ed927534bb8b590f45ad8025803c9bc (diff)
qcacld-3.0: Fix pmfComebackTimer during roaming
qcacld-2.0 to qcacld-3.0 propagation Currently pmfComebackTimer is not initialized during roaming. This can lead to error in pe_delete_session when driver tries to destroy pmfComebackTimer. Fix this by initializing pmfComebackTimer during roaming. Also, handle status eSIR_MAC_TRY_AGAIN_LATER as failure during roaming. Change-Id: Ic9c4e996c4078d09ef7cd9b3b073105d94eb53fb CRs-Fixed: 1037640
-rw-r--r--core/mac/src/pe/lim/lim_ft.c14
-rw-r--r--core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c27
2 files changed, 39 insertions, 2 deletions
diff --git a/core/mac/src/pe/lim/lim_ft.c b/core/mac/src/pe/lim/lim_ft.c
index c8abf3256b27..ba6ef6ce34cc 100644
--- a/core/mac/src/pe/lim/lim_ft.c
+++ b/core/mac/src/pe/lim/lim_ft.c
@@ -493,6 +493,7 @@ void lim_fill_ft_session(tpAniSirGlobal pMac,
tSchBeaconStruct *pBeaconStruct;
uint32_t selfDot11Mode;
ePhyChanBondState cbEnabledMode;
+ QDF_STATUS status;
pBeaconStruct = qdf_mem_malloc(sizeof(tSchBeaconStruct));
if (NULL == pBeaconStruct) {
@@ -678,6 +679,19 @@ void lim_fill_ft_session(tpAniSirGlobal pMac,
pftSessionEntry->encryptType = psessionEntry->encryptType;
#ifdef WLAN_FEATURE_11W
pftSessionEntry->limRmfEnabled = psessionEntry->limRmfEnabled;
+
+ if (pftSessionEntry->limRmfEnabled) {
+ pftSessionEntry->pmfComebackTimerInfo.pMac = pMac;
+ pftSessionEntry->pmfComebackTimerInfo.sessionID =
+ psessionEntry->smeSessionId;
+ status = qdf_mc_timer_init(&pftSessionEntry->pmfComebackTimer,
+ QDF_TIMER_TYPE_SW, lim_pmf_comeback_timer_callback,
+ (void *)&pftSessionEntry->pmfComebackTimerInfo);
+ if (!QDF_IS_STATUS_SUCCESS(status))
+ lim_log(pMac, LOGE,
+ FL("cannot init pmf comeback timer."));
+ }
+
#endif
if ((pftSessionEntry->limRFBand == SIR_BAND_2_4_GHZ) &&
(pftSessionEntry->htSupportedChannelWidthSet ==
diff --git a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
index 573a2884da00..80c897413c65 100644
--- a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
+++ b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
@@ -810,11 +810,34 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx,
timeout_value)) {
lim_log(mac_ctx, LOGE,
FL("Failed to start comeback timer."));
+
+ assoc_cnf.resultCode = eSIR_SME_ASSOC_REFUSED;
+ assoc_cnf.protStatusCode =
+ eSIR_MAC_UNSPEC_FAILURE_STATUS;
+
+ /*
+ * Delete Pre-auth context for the
+ * associated BSS
+ */
+ if (lim_search_pre_auth_list(mac_ctx, hdr->sa))
+ lim_delete_pre_auth_node(mac_ctx,
+ hdr->sa);
+
+ goto assocReject;
}
} else {
lim_log(mac_ctx, LOGW,
- FL("ASSOC resp with try again event recvd. "
- "But try again time interval IE is wrong."));
+ FL("ASSOC resp with try again event recvd, but try again time interval IE is wrong"));
+
+ assoc_cnf.resultCode = eSIR_SME_ASSOC_REFUSED;
+ assoc_cnf.protStatusCode =
+ eSIR_MAC_UNSPEC_FAILURE_STATUS;
+
+ /* Delete Pre-auth context for the associated BSS */
+ if (lim_search_pre_auth_list(mac_ctx, hdr->sa))
+ lim_delete_pre_auth_node(mac_ctx, hdr->sa);
+
+ goto assocReject;
}
qdf_mem_free(beacon);
qdf_mem_free(assoc_rsp);