aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless/nl80211.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/wireless/nl80211.c')
-rw-r--r--net/wireless/nl80211.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 9c6e23ede5b2..66666fdf1c8d 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -7265,8 +7265,18 @@ static int nl80211_join_ibss(struct sk_buff *skb, struct genl_info *info)
7265 break; 7265 break;
7266 case NL80211_CHAN_WIDTH_20: 7266 case NL80211_CHAN_WIDTH_20:
7267 case NL80211_CHAN_WIDTH_40: 7267 case NL80211_CHAN_WIDTH_40:
7268 if (rdev->wiphy.features & NL80211_FEATURE_HT_IBSS) 7268 if (!(rdev->wiphy.features & NL80211_FEATURE_HT_IBSS))
7269 break; 7269 return -EINVAL;
7270 break;
7271 case NL80211_CHAN_WIDTH_80:
7272 case NL80211_CHAN_WIDTH_80P80:
7273 case NL80211_CHAN_WIDTH_160:
7274 if (!(rdev->wiphy.features & NL80211_FEATURE_HT_IBSS))
7275 return -EINVAL;
7276 if (!wiphy_ext_feature_isset(&rdev->wiphy,
7277 NL80211_EXT_FEATURE_VHT_IBSS))
7278 return -EINVAL;
7279 break;
7270 default: 7280 default:
7271 return -EINVAL; 7281 return -EINVAL;
7272 } 7282 }