提交 c8f42315 编写于 作者: J Johannes Berg 提交者: Emmanuel Grumbach

iwlwifi: mvm: remove pointless scan plan checks

As cfg80211 already enforces these limits, there's little point
in having them again here in our code.
Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
Signed-off-by: NEmmanuel Grumbach <emmanuel.grumbach@intel.com>
上级 46eebec9
......@@ -819,16 +819,9 @@ static int iwl_mvm_scan_lmac(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
ssid_bitmap <<= 1;
for (i = 0; i < params->n_scan_plans; i++) {
struct wiphy *wiphy = mvm->hw->wiphy;
struct cfg80211_sched_scan_plan *scan_plan =
&params->scan_plans[i];
if (WARN_ON(scan_plan->iterations >
wiphy->max_sched_scan_plan_iterations ||
scan_plan->interval >
wiphy->max_sched_scan_plan_interval))
return -EINVAL;
cmd->schedule[i].delay =
cpu_to_le16(scan_plan->interval);
cmd->schedule[i].iterations = scan_plan->iterations;
......@@ -1103,16 +1096,9 @@ static int iwl_mvm_scan_umac(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
params->n_channels, ssid_bitmap, cmd);
for (i = 0; i < params->n_scan_plans; i++) {
struct wiphy *wiphy = mvm->hw->wiphy;
struct cfg80211_sched_scan_plan *scan_plan =
&params->scan_plans[i];
if (WARN_ON(scan_plan->iterations >
wiphy->max_sched_scan_plan_iterations ||
scan_plan->interval >
wiphy->max_sched_scan_plan_interval))
return -EINVAL;
sec_part->schedule[i].iter_count = scan_plan->iterations;
sec_part->schedule[i].interval =
cpu_to_le16(scan_plan->interval);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册