diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 56540c3701ed..bab82052255c 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -1981,6 +1981,12 @@ static int sta_link_apply_parameters(struct ieee80211_local *local, ieee80211_sta_init_nss(link_sta); if (params->opmode_notif_used) { + enum nl80211_chan_width width = link->conf->chanreq.oper.width; + /* VHT doesn't support 5/10 MHz channel widths */ + if (width == NL80211_CHAN_WIDTH_5 || + width == NL80211_CHAN_WIDTH_10) + return -EINVAL; + /* returned value is only needed for rc update, but the * rc isn't initialized here yet, so ignore it */