Browse Source

qcacld-3.0: Fix incorrect channel switch info during CSA

qcacld-2.0 to qcacld-3.0 propagation

In the current code, when STA receives CSA IE then host look and
operate on extended channel switch element eventhough our own
channel-bonding state is not enabled. This causes setting up of
secondary subband and state in new channel during CSA eventhough
the secondary channel offset is set to zero in CSA beacon.

Fix is to set the Secondary Channel Offset if our own channel
bonding state is enabled.

Change-Id: I82ca9737f49937176801bc4cbbdd3e2fb77d4749
CRs-Fixed: 1080260
Abhishek Singh 8 năm trước cách đây
mục cha
commit
e586ade30d
1 tập tin đã thay đổi với 12 bổ sung6 xóa
  1. 12 6
      core/mac/src/pe/lim/lim_process_tdls.c

+ 12 - 6
core/mac/src/pe/lim/lim_process_tdls.c

@@ -2652,15 +2652,21 @@ static void lim_tdls_update_hash_node_info(tpAniSirGlobal pMac,
 		pStaDs->vhtSupportedChannelWidthSet =
 			WNI_CFG_VHT_CHANNEL_WIDTH_20_40MHZ;
 	}
-	/*Calculate the Secondary Coannel Offset */
-	cbMode = lim_select_cb_mode(pStaDs, psessionEntry,
+
+	/*
+	 * Calculate the Secondary Coannel Offset if our
+	 * own channel bonding state is enabled
+	 */
+	if (psessionEntry->htSupportedChannelWidthSet) {
+		cbMode = lim_select_cb_mode(pStaDs, psessionEntry,
 				    psessionEntry->currentOperChannel,
 				    pStaDs->vhtSupportedChannelWidthSet);
 
-	pStaDs->htSecondaryChannelOffset = cbMode;
-
-	if (pStaDs->mlmStaContext.vhtCapability) {
-		pStaDs->htSecondaryChannelOffset = lim_get_htcb_state(cbMode);
+		if (pStaDs->mlmStaContext.vhtCapability)
+			pStaDs->htSecondaryChannelOffset =
+					lim_get_htcb_state(cbMode);
+		else
+			pStaDs->htSecondaryChannelOffset = cbMode;
 	}
 	pSessStaDs = dph_lookup_hash_entry(pMac, psessionEntry->bssId, &aid,
 					   &psessionEntry->dph.dphHashTable);