Skip to content

Commit 461ce35

Browse files
committed
cfg80211: reject HT/VHT capabilities on 6 GHz band
On the 6 GHz band, HE should be used, but without any direct HT/VHT capabilities, instead the HE 6 GHz band capabilities will capture the relevant information. Reject HT/VHT capabilities here. Link: https://lore.kernel.org/r/20200528213443.bfe89c35459a.Ibba5e066fa0087fd49d13cfee89d196ea0c68ae2@changeid Signed-off-by: Johannes Berg <[email protected]>
1 parent ba8f6a0 commit 461ce35

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

net/wireless/core.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* Copyright 2006-2010 Johannes Berg <[email protected]>
66
* Copyright 2013-2014 Intel Mobile Communications GmbH
77
* Copyright 2015-2017 Intel Deutschland GmbH
8-
* Copyright (C) 2018-2019 Intel Corporation
8+
* Copyright (C) 2018-2020 Intel Corporation
99
*/
1010

1111
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
@@ -807,6 +807,11 @@ int wiphy_register(struct wiphy *wiphy)
807807
!sband->n_bitrates))
808808
return -EINVAL;
809809

810+
if (WARN_ON(band == NL80211_BAND_6GHZ &&
811+
(sband->ht_cap.ht_supported ||
812+
sband->vht_cap.vht_supported)))
813+
return -EINVAL;
814+
810815
/*
811816
* Since cfg80211_disable_40mhz_24ghz is global, we can
812817
* modify the sband's ht data even if the driver uses a

0 commit comments

Comments
 (0)