瀏覽代碼

qcacld-3.0: Configure join timeout based on beacon interval

Join timeout can be configured to 10 times the beacon interval
of the candidate beacon if it is in bounds with the join failure
timeout ini. However, host always configures join failure timer
with the default join failure timeout.

Fix the join failure timeout calculation by considering the
beacon interval.

CRs-Fixed: 3628892
Change-Id: I6c238c7db8ad6925c11fa97b3a698643187fec95
Surya Prakash Sivaraj 1 年之前
父節點
當前提交
d843f3767c
共有 1 個文件被更改,包括 5 次插入1 次删除
  1. 5 1
      core/mac/src/pe/lim/lim_process_sme_req_messages.c

+ 5 - 1
core/mac/src/pe/lim/lim_process_sme_req_messages.c

@@ -3228,10 +3228,14 @@ lim_fill_pe_session(struct mac_context *mac_ctx, struct pe_session *session,
 	/*
 	 * Join timeout: if we find a BeaconInterval in the BssDescription,
 	 * then set the Join Timeout to be 10 x the BeaconInterval.
+	 *
+	 * 10 * BeaconInterval should be greater than the minimum join
+	 * timeout and lesser than the configured timeout.
 	 */
 	timeout = mac_ctx->mlme_cfg->timeouts.join_failure_timeout_ori;
 	if (bss_desc->beaconInterval)
-		timeout = QDF_MAX(10 * bss_desc->beaconInterval, timeout);
+		timeout = QDF_MAX(10 * bss_desc->beaconInterval,
+				  cfg_min(CFG_JOIN_FAILURE_TIMEOUT));
 
 	mac_ctx->mlme_cfg->timeouts.join_failure_timeout =
 		QDF_MIN(timeout,