فهرست منبع

iwlwifi: mvm: fix extended dwell time

FW adds 10 msec for every dwell time in low band, so we need
to set 10 msec less.
Don't use extended dwell time when fragmented scan is needed
because FW adds 3 msec per probe and it can easily exceed
max out of channel time.

Fixes: c3e230b167a9 ("iwlwifi: mvm: add extended dwell time")
Signed-off-by: David Spinadel <david.spinadel@intel.com>
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
David Spinadel 9 سال پیش
والد
کامیت
ca95ff3a9f
1فایلهای تغییر یافته به همراه7 افزوده شده و 6 حذف شده
  1. 7 6
      drivers/net/wireless/intel/iwlwifi/mvm/scan.c

+ 7 - 6
drivers/net/wireless/intel/iwlwifi/mvm/scan.c

@@ -92,7 +92,7 @@ static struct iwl_mvm_scan_timing_params scan_timing[] = {
 		.dwell_active = 10,
 		.dwell_active = 10,
 		.dwell_passive = 110,
 		.dwell_passive = 110,
 		.dwell_fragmented = 44,
 		.dwell_fragmented = 44,
-		.dwell_extended = 100,
+		.dwell_extended = 90,
 		.suspend_time = 0,
 		.suspend_time = 0,
 		.max_out_time = 0,
 		.max_out_time = 0,
 	},
 	},
@@ -100,7 +100,7 @@ static struct iwl_mvm_scan_timing_params scan_timing[] = {
 		.dwell_active = 10,
 		.dwell_active = 10,
 		.dwell_passive = 110,
 		.dwell_passive = 110,
 		.dwell_fragmented = 44,
 		.dwell_fragmented = 44,
-		.dwell_extended = 100,
+		.dwell_extended = 90,
 		.suspend_time = 30,
 		.suspend_time = 30,
 		.max_out_time = 120,
 		.max_out_time = 120,
 	},
 	},
@@ -108,7 +108,7 @@ static struct iwl_mvm_scan_timing_params scan_timing[] = {
 		.dwell_active = 10,
 		.dwell_active = 10,
 		.dwell_passive = 110,
 		.dwell_passive = 110,
 		.dwell_fragmented = 44,
 		.dwell_fragmented = 44,
-		.dwell_extended = 100,
+		.dwell_extended = 90,
 		.suspend_time = 120,
 		.suspend_time = 120,
 		.max_out_time = 120,
 		.max_out_time = 120,
 	},
 	},
@@ -116,7 +116,6 @@ static struct iwl_mvm_scan_timing_params scan_timing[] = {
 		.dwell_active = 10,
 		.dwell_active = 10,
 		.dwell_passive = 110,
 		.dwell_passive = 110,
 		.dwell_fragmented = 44,
 		.dwell_fragmented = 44,
-		.dwell_extended = 44,
 		.suspend_time = 95,
 		.suspend_time = 95,
 		.max_out_time = 44,
 		.max_out_time = 44,
 	},
 	},
@@ -790,7 +789,8 @@ static int iwl_mvm_scan_lmac_flags(struct iwl_mvm *mvm,
 #endif
 #endif
 
 
 	if (iwl_mvm_is_regular_scan(params) &&
 	if (iwl_mvm_is_regular_scan(params) &&
-	    vif->type != NL80211_IFTYPE_P2P_DEVICE)
+	    vif->type != NL80211_IFTYPE_P2P_DEVICE &&
+	    params->type != IWL_SCAN_TYPE_FRAGMENTED)
 		flags |= IWL_MVM_LMAC_SCAN_FLAG_EXTENDED_DWELL;
 		flags |= IWL_MVM_LMAC_SCAN_FLAG_EXTENDED_DWELL;
 
 
 	return flags;
 	return flags;
@@ -1072,7 +1072,8 @@ static u32 iwl_mvm_scan_umac_flags(struct iwl_mvm *mvm,
 #endif
 #endif
 
 
 	if (iwl_mvm_is_regular_scan(params) &&
 	if (iwl_mvm_is_regular_scan(params) &&
-	    vif->type != NL80211_IFTYPE_P2P_DEVICE)
+	    vif->type != NL80211_IFTYPE_P2P_DEVICE &&
+	    params->type != IWL_SCAN_TYPE_FRAGMENTED)
 		flags |= IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL;
 		flags |= IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL;
 
 
 	return flags;
 	return flags;