diff options
Diffstat (limited to 'net/wireless/chan.c')
-rw-r--r-- | net/wireless/chan.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/wireless/chan.c b/net/wireless/chan.c index 84d686e2dbd0..992b34070bcb 100644 --- a/net/wireless/chan.c +++ b/net/wireless/chan.c | |||
@@ -370,8 +370,8 @@ int cfg80211_chandef_dfs_required(struct wiphy *wiphy, | |||
370 | case NL80211_IFTYPE_AP_VLAN: | 370 | case NL80211_IFTYPE_AP_VLAN: |
371 | case NL80211_IFTYPE_WDS: | 371 | case NL80211_IFTYPE_WDS: |
372 | case NL80211_IFTYPE_P2P_DEVICE: | 372 | case NL80211_IFTYPE_P2P_DEVICE: |
373 | case NL80211_IFTYPE_UNSPECIFIED: | ||
374 | break; | 373 | break; |
374 | case NL80211_IFTYPE_UNSPECIFIED: | ||
375 | case NUM_NL80211_IFTYPES: | 375 | case NUM_NL80211_IFTYPES: |
376 | WARN_ON(1); | 376 | WARN_ON(1); |
377 | } | 377 | } |
@@ -796,8 +796,7 @@ bool cfg80211_reg_can_beacon(struct wiphy *wiphy, | |||
796 | !cfg80211_go_permissive_chan(rdev, chandef->chan)) | 796 | !cfg80211_go_permissive_chan(rdev, chandef->chan)) |
797 | prohibited_flags |= IEEE80211_CHAN_NO_IR; | 797 | prohibited_flags |= IEEE80211_CHAN_NO_IR; |
798 | 798 | ||
799 | if (cfg80211_chandef_dfs_required(wiphy, chandef, | 799 | if (cfg80211_chandef_dfs_required(wiphy, chandef, iftype) > 0 && |
800 | NL80211_IFTYPE_UNSPECIFIED) > 0 && | ||
801 | cfg80211_chandef_dfs_available(wiphy, chandef)) { | 800 | cfg80211_chandef_dfs_available(wiphy, chandef)) { |
802 | /* We can skip IEEE80211_CHAN_NO_IR if chandef dfs available */ | 801 | /* We can skip IEEE80211_CHAN_NO_IR if chandef dfs available */ |
803 | prohibited_flags = IEEE80211_CHAN_DISABLED; | 802 | prohibited_flags = IEEE80211_CHAN_DISABLED; |