Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

wifi: ieee80211: split VHT definitions out

The ieee80211.h file has gotten very long, continue splitting
it by putting VHT definitions into a separate file.

Link: https://patch.msgid.link/20251105153843.c31cb771a250.I787a13064db7d80440101de3445be17881daf1b6@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>

+237 -215
+236
include/linux/ieee80211-vht.h
··· 1 + /* SPDX-License-Identifier: GPL-2.0-only */ 2 + /* 3 + * IEEE 802.11 VHT definitions 4 + * 5 + * Copyright (c) 2001-2002, SSH Communications Security Corp and Jouni Malinen 6 + * <jkmaline@cc.hut.fi> 7 + * Copyright (c) 2002-2003, Jouni Malinen <jkmaline@cc.hut.fi> 8 + * Copyright (c) 2005, Devicescape Software, Inc. 9 + * Copyright (c) 2006, Michael Wu <flamingice@sourmilk.net> 10 + * Copyright (c) 2013 - 2014 Intel Mobile Communications GmbH 11 + * Copyright (c) 2016 - 2017 Intel Deutschland GmbH 12 + * Copyright (c) 2018 - 2025 Intel Corporation 13 + */ 14 + 15 + #ifndef LINUX_IEEE80211_VHT_H 16 + #define LINUX_IEEE80211_VHT_H 17 + 18 + #include <linux/types.h> 19 + #include <linux/if_ether.h> 20 + 21 + #define IEEE80211_MAX_MPDU_LEN_VHT_3895 3895 22 + #define IEEE80211_MAX_MPDU_LEN_VHT_7991 7991 23 + #define IEEE80211_MAX_MPDU_LEN_VHT_11454 11454 24 + 25 + /** 26 + * enum ieee80211_vht_opmode_bits - VHT operating mode field bits 27 + * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_MASK: channel width mask 28 + * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_20MHZ: 20 MHz channel width 29 + * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_40MHZ: 40 MHz channel width 30 + * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_80MHZ: 80 MHz channel width 31 + * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_160MHZ: 160 MHz or 80+80 MHz channel width 32 + * @IEEE80211_OPMODE_NOTIF_BW_160_80P80: 160 / 80+80 MHz indicator flag 33 + * @IEEE80211_OPMODE_NOTIF_RX_NSS_MASK: number of spatial streams mask 34 + * (the NSS value is the value of this field + 1) 35 + * @IEEE80211_OPMODE_NOTIF_RX_NSS_SHIFT: number of spatial streams shift 36 + * @IEEE80211_OPMODE_NOTIF_RX_NSS_TYPE_BF: indicates streams in SU-MIMO PPDU 37 + * using a beamforming steering matrix 38 + */ 39 + enum ieee80211_vht_opmode_bits { 40 + IEEE80211_OPMODE_NOTIF_CHANWIDTH_MASK = 0x03, 41 + IEEE80211_OPMODE_NOTIF_CHANWIDTH_20MHZ = 0, 42 + IEEE80211_OPMODE_NOTIF_CHANWIDTH_40MHZ = 1, 43 + IEEE80211_OPMODE_NOTIF_CHANWIDTH_80MHZ = 2, 44 + IEEE80211_OPMODE_NOTIF_CHANWIDTH_160MHZ = 3, 45 + IEEE80211_OPMODE_NOTIF_BW_160_80P80 = 0x04, 46 + IEEE80211_OPMODE_NOTIF_RX_NSS_MASK = 0x70, 47 + IEEE80211_OPMODE_NOTIF_RX_NSS_SHIFT = 4, 48 + IEEE80211_OPMODE_NOTIF_RX_NSS_TYPE_BF = 0x80, 49 + }; 50 + 51 + /* 52 + * Maximum length of AMPDU that the STA can receive in VHT. 53 + * Length = 2 ^ (13 + max_ampdu_length_exp) - 1 (octets) 54 + */ 55 + enum ieee80211_vht_max_ampdu_length_exp { 56 + IEEE80211_VHT_MAX_AMPDU_8K = 0, 57 + IEEE80211_VHT_MAX_AMPDU_16K = 1, 58 + IEEE80211_VHT_MAX_AMPDU_32K = 2, 59 + IEEE80211_VHT_MAX_AMPDU_64K = 3, 60 + IEEE80211_VHT_MAX_AMPDU_128K = 4, 61 + IEEE80211_VHT_MAX_AMPDU_256K = 5, 62 + IEEE80211_VHT_MAX_AMPDU_512K = 6, 63 + IEEE80211_VHT_MAX_AMPDU_1024K = 7 64 + }; 65 + 66 + /** 67 + * struct ieee80211_vht_mcs_info - VHT MCS information 68 + * @rx_mcs_map: RX MCS map 2 bits for each stream, total 8 streams 69 + * @rx_highest: Indicates highest long GI VHT PPDU data rate 70 + * STA can receive. Rate expressed in units of 1 Mbps. 71 + * If this field is 0 this value should not be used to 72 + * consider the highest RX data rate supported. 73 + * The top 3 bits of this field indicate the Maximum NSTS,total 74 + * (a beamformee capability.) 75 + * @tx_mcs_map: TX MCS map 2 bits for each stream, total 8 streams 76 + * @tx_highest: Indicates highest long GI VHT PPDU data rate 77 + * STA can transmit. Rate expressed in units of 1 Mbps. 78 + * If this field is 0 this value should not be used to 79 + * consider the highest TX data rate supported. 80 + * The top 2 bits of this field are reserved, the 81 + * 3rd bit from the top indiciates VHT Extended NSS BW 82 + * Capability. 83 + */ 84 + struct ieee80211_vht_mcs_info { 85 + __le16 rx_mcs_map; 86 + __le16 rx_highest; 87 + __le16 tx_mcs_map; 88 + __le16 tx_highest; 89 + } __packed; 90 + 91 + /* for rx_highest */ 92 + #define IEEE80211_VHT_MAX_NSTS_TOTAL_SHIFT 13 93 + #define IEEE80211_VHT_MAX_NSTS_TOTAL_MASK (7 << IEEE80211_VHT_MAX_NSTS_TOTAL_SHIFT) 94 + 95 + /* for tx_highest */ 96 + #define IEEE80211_VHT_EXT_NSS_BW_CAPABLE (1 << 13) 97 + 98 + /** 99 + * enum ieee80211_vht_mcs_support - VHT MCS support definitions 100 + * @IEEE80211_VHT_MCS_SUPPORT_0_7: MCSes 0-7 are supported for the 101 + * number of streams 102 + * @IEEE80211_VHT_MCS_SUPPORT_0_8: MCSes 0-8 are supported 103 + * @IEEE80211_VHT_MCS_SUPPORT_0_9: MCSes 0-9 are supported 104 + * @IEEE80211_VHT_MCS_NOT_SUPPORTED: This number of streams isn't supported 105 + * 106 + * These definitions are used in each 2-bit subfield of the @rx_mcs_map 107 + * and @tx_mcs_map fields of &struct ieee80211_vht_mcs_info, which are 108 + * both split into 8 subfields by number of streams. These values indicate 109 + * which MCSes are supported for the number of streams the value appears 110 + * for. 111 + */ 112 + enum ieee80211_vht_mcs_support { 113 + IEEE80211_VHT_MCS_SUPPORT_0_7 = 0, 114 + IEEE80211_VHT_MCS_SUPPORT_0_8 = 1, 115 + IEEE80211_VHT_MCS_SUPPORT_0_9 = 2, 116 + IEEE80211_VHT_MCS_NOT_SUPPORTED = 3, 117 + }; 118 + 119 + /** 120 + * struct ieee80211_vht_cap - VHT capabilities 121 + * 122 + * This structure is the "VHT capabilities element" as 123 + * described in 802.11ac D3.0 8.4.2.160 124 + * @vht_cap_info: VHT capability info 125 + * @supp_mcs: VHT MCS supported rates 126 + */ 127 + struct ieee80211_vht_cap { 128 + __le32 vht_cap_info; 129 + struct ieee80211_vht_mcs_info supp_mcs; 130 + } __packed; 131 + 132 + /** 133 + * enum ieee80211_vht_chanwidth - VHT channel width 134 + * @IEEE80211_VHT_CHANWIDTH_USE_HT: use the HT operation IE to 135 + * determine the channel width (20 or 40 MHz) 136 + * @IEEE80211_VHT_CHANWIDTH_80MHZ: 80 MHz bandwidth 137 + * @IEEE80211_VHT_CHANWIDTH_160MHZ: 160 MHz bandwidth 138 + * @IEEE80211_VHT_CHANWIDTH_80P80MHZ: 80+80 MHz bandwidth 139 + */ 140 + enum ieee80211_vht_chanwidth { 141 + IEEE80211_VHT_CHANWIDTH_USE_HT = 0, 142 + IEEE80211_VHT_CHANWIDTH_80MHZ = 1, 143 + IEEE80211_VHT_CHANWIDTH_160MHZ = 2, 144 + IEEE80211_VHT_CHANWIDTH_80P80MHZ = 3, 145 + }; 146 + 147 + /** 148 + * struct ieee80211_vht_operation - VHT operation IE 149 + * 150 + * This structure is the "VHT operation element" as 151 + * described in 802.11ac D3.0 8.4.2.161 152 + * @chan_width: Operating channel width 153 + * @center_freq_seg0_idx: center freq segment 0 index 154 + * @center_freq_seg1_idx: center freq segment 1 index 155 + * @basic_mcs_set: VHT Basic MCS rate set 156 + */ 157 + struct ieee80211_vht_operation { 158 + u8 chan_width; 159 + u8 center_freq_seg0_idx; 160 + u8 center_freq_seg1_idx; 161 + __le16 basic_mcs_set; 162 + } __packed; 163 + 164 + /* 802.11ac VHT Capabilities */ 165 + #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_3895 0x00000000 166 + #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_7991 0x00000001 167 + #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_11454 0x00000002 168 + #define IEEE80211_VHT_CAP_MAX_MPDU_MASK 0x00000003 169 + #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_160MHZ 0x00000004 170 + #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_160_80PLUS80MHZ 0x00000008 171 + #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_MASK 0x0000000C 172 + #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_SHIFT 2 173 + #define IEEE80211_VHT_CAP_RXLDPC 0x00000010 174 + #define IEEE80211_VHT_CAP_SHORT_GI_80 0x00000020 175 + #define IEEE80211_VHT_CAP_SHORT_GI_160 0x00000040 176 + #define IEEE80211_VHT_CAP_TXSTBC 0x00000080 177 + #define IEEE80211_VHT_CAP_RXSTBC_1 0x00000100 178 + #define IEEE80211_VHT_CAP_RXSTBC_2 0x00000200 179 + #define IEEE80211_VHT_CAP_RXSTBC_3 0x00000300 180 + #define IEEE80211_VHT_CAP_RXSTBC_4 0x00000400 181 + #define IEEE80211_VHT_CAP_RXSTBC_MASK 0x00000700 182 + #define IEEE80211_VHT_CAP_RXSTBC_SHIFT 8 183 + #define IEEE80211_VHT_CAP_SU_BEAMFORMER_CAPABLE 0x00000800 184 + #define IEEE80211_VHT_CAP_SU_BEAMFORMEE_CAPABLE 0x00001000 185 + #define IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT 13 186 + #define IEEE80211_VHT_CAP_BEAMFORMEE_STS_MASK \ 187 + (7 << IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT) 188 + #define IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_SHIFT 16 189 + #define IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_MASK \ 190 + (7 << IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_SHIFT) 191 + #define IEEE80211_VHT_CAP_MU_BEAMFORMER_CAPABLE 0x00080000 192 + #define IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE 0x00100000 193 + #define IEEE80211_VHT_CAP_VHT_TXOP_PS 0x00200000 194 + #define IEEE80211_VHT_CAP_HTC_VHT 0x00400000 195 + #define IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_SHIFT 23 196 + #define IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_MASK \ 197 + (7 << IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_SHIFT) 198 + #define IEEE80211_VHT_CAP_VHT_LINK_ADAPTATION_VHT_UNSOL_MFB 0x08000000 199 + #define IEEE80211_VHT_CAP_VHT_LINK_ADAPTATION_VHT_MRQ_MFB 0x0c000000 200 + #define IEEE80211_VHT_CAP_RX_ANTENNA_PATTERN 0x10000000 201 + #define IEEE80211_VHT_CAP_TX_ANTENNA_PATTERN 0x20000000 202 + #define IEEE80211_VHT_CAP_EXT_NSS_BW_SHIFT 30 203 + #define IEEE80211_VHT_CAP_EXT_NSS_BW_MASK 0xc0000000 204 + 205 + /** 206 + * ieee80211_get_vht_max_nss - return max NSS for a given bandwidth/MCS 207 + * @cap: VHT capabilities of the peer 208 + * @bw: bandwidth to use 209 + * @mcs: MCS index to use 210 + * @ext_nss_bw_capable: indicates whether or not the local transmitter 211 + * (rate scaling algorithm) can deal with the new logic 212 + * (dot11VHTExtendedNSSBWCapable) 213 + * @max_vht_nss: current maximum NSS as advertised by the STA in 214 + * operating mode notification, can be 0 in which case the 215 + * capability data will be used to derive this (from MCS support) 216 + * Return: The maximum NSS that can be used for the given bandwidth/MCS 217 + * combination 218 + * 219 + * Due to the VHT Extended NSS Bandwidth Support, the maximum NSS can 220 + * vary for a given BW/MCS. This function parses the data. 221 + * 222 + * Note: This function is exported by cfg80211. 223 + */ 224 + int ieee80211_get_vht_max_nss(struct ieee80211_vht_cap *cap, 225 + enum ieee80211_vht_chanwidth bw, 226 + int mcs, bool ext_nss_bw_capable, 227 + unsigned int max_vht_nss); 228 + 229 + /* VHT action codes */ 230 + enum ieee80211_vht_actioncode { 231 + WLAN_VHT_ACTION_COMPRESSED_BF = 0, 232 + WLAN_VHT_ACTION_GROUPID_MGMT = 1, 233 + WLAN_VHT_ACTION_OPMODE_NOTIF = 2, 234 + }; 235 + 236 + #endif /* LINUX_IEEE80211_VHT_H */
+1 -215
include/linux/ieee80211.h
··· 239 239 /* 30 byte 4 addr hdr, 2 byte QoS, 2304 byte MSDU, 12 byte crypt, 4 byte FCS */ 240 240 #define IEEE80211_MAX_FRAME_LEN 2352 241 241 242 - #define IEEE80211_MAX_MPDU_LEN_VHT_3895 3895 243 - #define IEEE80211_MAX_MPDU_LEN_VHT_7991 7991 244 - #define IEEE80211_MAX_MPDU_LEN_VHT_11454 11454 245 - 246 242 #define IEEE80211_MAX_SSID_LEN 32 247 243 248 244 #define IEEE80211_FIRST_TSPEC_TSID 8 ··· 985 989 } __packed; 986 990 987 991 /** 988 - * enum ieee80211_vht_opmode_bits - VHT operating mode field bits 989 - * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_MASK: channel width mask 990 - * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_20MHZ: 20 MHz channel width 991 - * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_40MHZ: 40 MHz channel width 992 - * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_80MHZ: 80 MHz channel width 993 - * @IEEE80211_OPMODE_NOTIF_CHANWIDTH_160MHZ: 160 MHz or 80+80 MHz channel width 994 - * @IEEE80211_OPMODE_NOTIF_BW_160_80P80: 160 / 80+80 MHz indicator flag 995 - * @IEEE80211_OPMODE_NOTIF_RX_NSS_MASK: number of spatial streams mask 996 - * (the NSS value is the value of this field + 1) 997 - * @IEEE80211_OPMODE_NOTIF_RX_NSS_SHIFT: number of spatial streams shift 998 - * @IEEE80211_OPMODE_NOTIF_RX_NSS_TYPE_BF: indicates streams in SU-MIMO PPDU 999 - * using a beamforming steering matrix 1000 - */ 1001 - enum ieee80211_vht_opmode_bits { 1002 - IEEE80211_OPMODE_NOTIF_CHANWIDTH_MASK = 0x03, 1003 - IEEE80211_OPMODE_NOTIF_CHANWIDTH_20MHZ = 0, 1004 - IEEE80211_OPMODE_NOTIF_CHANWIDTH_40MHZ = 1, 1005 - IEEE80211_OPMODE_NOTIF_CHANWIDTH_80MHZ = 2, 1006 - IEEE80211_OPMODE_NOTIF_CHANWIDTH_160MHZ = 3, 1007 - IEEE80211_OPMODE_NOTIF_BW_160_80P80 = 0x04, 1008 - IEEE80211_OPMODE_NOTIF_RX_NSS_MASK = 0x70, 1009 - IEEE80211_OPMODE_NOTIF_RX_NSS_SHIFT = 4, 1010 - IEEE80211_OPMODE_NOTIF_RX_NSS_TYPE_BF = 0x80, 1011 - }; 1012 - 1013 - /** 1014 992 * enum ieee80211_s1g_chanwidth - S1G channel widths 1015 993 * These are defined in IEEE802.11-2016ah Table 10-20 1016 994 * as BSS Channel Width ··· 1633 1663 #define IEEE80211_P2P_OPPPS_ENABLE_BIT BIT(7) 1634 1664 #define IEEE80211_P2P_OPPPS_CTWINDOW_MASK 0x7F 1635 1665 1636 - /* 1637 - * Maximum length of AMPDU that the STA can receive in VHT. 1638 - * Length = 2 ^ (13 + max_ampdu_length_exp) - 1 (octets) 1639 - */ 1640 - enum ieee80211_vht_max_ampdu_length_exp { 1641 - IEEE80211_VHT_MAX_AMPDU_8K = 0, 1642 - IEEE80211_VHT_MAX_AMPDU_16K = 1, 1643 - IEEE80211_VHT_MAX_AMPDU_32K = 2, 1644 - IEEE80211_VHT_MAX_AMPDU_64K = 3, 1645 - IEEE80211_VHT_MAX_AMPDU_128K = 4, 1646 - IEEE80211_VHT_MAX_AMPDU_256K = 5, 1647 - IEEE80211_VHT_MAX_AMPDU_512K = 6, 1648 - IEEE80211_VHT_MAX_AMPDU_1024K = 7 1649 - }; 1650 - 1651 - /** 1652 - * struct ieee80211_vht_mcs_info - VHT MCS information 1653 - * @rx_mcs_map: RX MCS map 2 bits for each stream, total 8 streams 1654 - * @rx_highest: Indicates highest long GI VHT PPDU data rate 1655 - * STA can receive. Rate expressed in units of 1 Mbps. 1656 - * If this field is 0 this value should not be used to 1657 - * consider the highest RX data rate supported. 1658 - * The top 3 bits of this field indicate the Maximum NSTS,total 1659 - * (a beamformee capability.) 1660 - * @tx_mcs_map: TX MCS map 2 bits for each stream, total 8 streams 1661 - * @tx_highest: Indicates highest long GI VHT PPDU data rate 1662 - * STA can transmit. Rate expressed in units of 1 Mbps. 1663 - * If this field is 0 this value should not be used to 1664 - * consider the highest TX data rate supported. 1665 - * The top 2 bits of this field are reserved, the 1666 - * 3rd bit from the top indiciates VHT Extended NSS BW 1667 - * Capability. 1668 - */ 1669 - struct ieee80211_vht_mcs_info { 1670 - __le16 rx_mcs_map; 1671 - __le16 rx_highest; 1672 - __le16 tx_mcs_map; 1673 - __le16 tx_highest; 1674 - } __packed; 1675 - 1676 - /* for rx_highest */ 1677 - #define IEEE80211_VHT_MAX_NSTS_TOTAL_SHIFT 13 1678 - #define IEEE80211_VHT_MAX_NSTS_TOTAL_MASK (7 << IEEE80211_VHT_MAX_NSTS_TOTAL_SHIFT) 1679 - 1680 - /* for tx_highest */ 1681 - #define IEEE80211_VHT_EXT_NSS_BW_CAPABLE (1 << 13) 1682 - 1683 - /** 1684 - * enum ieee80211_vht_mcs_support - VHT MCS support definitions 1685 - * @IEEE80211_VHT_MCS_SUPPORT_0_7: MCSes 0-7 are supported for the 1686 - * number of streams 1687 - * @IEEE80211_VHT_MCS_SUPPORT_0_8: MCSes 0-8 are supported 1688 - * @IEEE80211_VHT_MCS_SUPPORT_0_9: MCSes 0-9 are supported 1689 - * @IEEE80211_VHT_MCS_NOT_SUPPORTED: This number of streams isn't supported 1690 - * 1691 - * These definitions are used in each 2-bit subfield of the @rx_mcs_map 1692 - * and @tx_mcs_map fields of &struct ieee80211_vht_mcs_info, which are 1693 - * both split into 8 subfields by number of streams. These values indicate 1694 - * which MCSes are supported for the number of streams the value appears 1695 - * for. 1696 - */ 1697 - enum ieee80211_vht_mcs_support { 1698 - IEEE80211_VHT_MCS_SUPPORT_0_7 = 0, 1699 - IEEE80211_VHT_MCS_SUPPORT_0_8 = 1, 1700 - IEEE80211_VHT_MCS_SUPPORT_0_9 = 2, 1701 - IEEE80211_VHT_MCS_NOT_SUPPORTED = 3, 1702 - }; 1703 - 1704 - /** 1705 - * struct ieee80211_vht_cap - VHT capabilities 1706 - * 1707 - * This structure is the "VHT capabilities element" as 1708 - * described in 802.11ac D3.0 8.4.2.160 1709 - * @vht_cap_info: VHT capability info 1710 - * @supp_mcs: VHT MCS supported rates 1711 - */ 1712 - struct ieee80211_vht_cap { 1713 - __le32 vht_cap_info; 1714 - struct ieee80211_vht_mcs_info supp_mcs; 1715 - } __packed; 1716 - 1717 - /** 1718 - * enum ieee80211_vht_chanwidth - VHT channel width 1719 - * @IEEE80211_VHT_CHANWIDTH_USE_HT: use the HT operation IE to 1720 - * determine the channel width (20 or 40 MHz) 1721 - * @IEEE80211_VHT_CHANWIDTH_80MHZ: 80 MHz bandwidth 1722 - * @IEEE80211_VHT_CHANWIDTH_160MHZ: 160 MHz bandwidth 1723 - * @IEEE80211_VHT_CHANWIDTH_80P80MHZ: 80+80 MHz bandwidth 1724 - */ 1725 - enum ieee80211_vht_chanwidth { 1726 - IEEE80211_VHT_CHANWIDTH_USE_HT = 0, 1727 - IEEE80211_VHT_CHANWIDTH_80MHZ = 1, 1728 - IEEE80211_VHT_CHANWIDTH_160MHZ = 2, 1729 - IEEE80211_VHT_CHANWIDTH_80P80MHZ = 3, 1730 - }; 1731 - 1732 - /** 1733 - * struct ieee80211_vht_operation - VHT operation IE 1734 - * 1735 - * This structure is the "VHT operation element" as 1736 - * described in 802.11ac D3.0 8.4.2.161 1737 - * @chan_width: Operating channel width 1738 - * @center_freq_seg0_idx: center freq segment 0 index 1739 - * @center_freq_seg1_idx: center freq segment 1 index 1740 - * @basic_mcs_set: VHT Basic MCS rate set 1741 - */ 1742 - struct ieee80211_vht_operation { 1743 - u8 chan_width; 1744 - u8 center_freq_seg0_idx; 1745 - u8 center_freq_seg1_idx; 1746 - __le16 basic_mcs_set; 1747 - } __packed; 1748 - 1749 1666 /** 1750 1667 * struct ieee80211_he_cap_elem - HE capabilities element 1751 1668 * @mac_cap_info: HE MAC Capabilities Information ··· 1901 2044 u8 ccfs1; 1902 2045 u8 optional[]; 1903 2046 } __packed; 1904 - 1905 - /* 802.11ac VHT Capabilities */ 1906 - #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_3895 0x00000000 1907 - #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_7991 0x00000001 1908 - #define IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_11454 0x00000002 1909 - #define IEEE80211_VHT_CAP_MAX_MPDU_MASK 0x00000003 1910 - #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_160MHZ 0x00000004 1911 - #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_160_80PLUS80MHZ 0x00000008 1912 - #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_MASK 0x0000000C 1913 - #define IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_SHIFT 2 1914 - #define IEEE80211_VHT_CAP_RXLDPC 0x00000010 1915 - #define IEEE80211_VHT_CAP_SHORT_GI_80 0x00000020 1916 - #define IEEE80211_VHT_CAP_SHORT_GI_160 0x00000040 1917 - #define IEEE80211_VHT_CAP_TXSTBC 0x00000080 1918 - #define IEEE80211_VHT_CAP_RXSTBC_1 0x00000100 1919 - #define IEEE80211_VHT_CAP_RXSTBC_2 0x00000200 1920 - #define IEEE80211_VHT_CAP_RXSTBC_3 0x00000300 1921 - #define IEEE80211_VHT_CAP_RXSTBC_4 0x00000400 1922 - #define IEEE80211_VHT_CAP_RXSTBC_MASK 0x00000700 1923 - #define IEEE80211_VHT_CAP_RXSTBC_SHIFT 8 1924 - #define IEEE80211_VHT_CAP_SU_BEAMFORMER_CAPABLE 0x00000800 1925 - #define IEEE80211_VHT_CAP_SU_BEAMFORMEE_CAPABLE 0x00001000 1926 - #define IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT 13 1927 - #define IEEE80211_VHT_CAP_BEAMFORMEE_STS_MASK \ 1928 - (7 << IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT) 1929 - #define IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_SHIFT 16 1930 - #define IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_MASK \ 1931 - (7 << IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_SHIFT) 1932 - #define IEEE80211_VHT_CAP_MU_BEAMFORMER_CAPABLE 0x00080000 1933 - #define IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE 0x00100000 1934 - #define IEEE80211_VHT_CAP_VHT_TXOP_PS 0x00200000 1935 - #define IEEE80211_VHT_CAP_HTC_VHT 0x00400000 1936 - #define IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_SHIFT 23 1937 - #define IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_MASK \ 1938 - (7 << IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_SHIFT) 1939 - #define IEEE80211_VHT_CAP_VHT_LINK_ADAPTATION_VHT_UNSOL_MFB 0x08000000 1940 - #define IEEE80211_VHT_CAP_VHT_LINK_ADAPTATION_VHT_MRQ_MFB 0x0c000000 1941 - #define IEEE80211_VHT_CAP_RX_ANTENNA_PATTERN 0x10000000 1942 - #define IEEE80211_VHT_CAP_TX_ANTENNA_PATTERN 0x20000000 1943 - #define IEEE80211_VHT_CAP_EXT_NSS_BW_SHIFT 30 1944 - #define IEEE80211_VHT_CAP_EXT_NSS_BW_MASK 0xc0000000 1945 - 1946 - /** 1947 - * ieee80211_get_vht_max_nss - return max NSS for a given bandwidth/MCS 1948 - * @cap: VHT capabilities of the peer 1949 - * @bw: bandwidth to use 1950 - * @mcs: MCS index to use 1951 - * @ext_nss_bw_capable: indicates whether or not the local transmitter 1952 - * (rate scaling algorithm) can deal with the new logic 1953 - * (dot11VHTExtendedNSSBWCapable) 1954 - * @max_vht_nss: current maximum NSS as advertised by the STA in 1955 - * operating mode notification, can be 0 in which case the 1956 - * capability data will be used to derive this (from MCS support) 1957 - * Return: The maximum NSS that can be used for the given bandwidth/MCS 1958 - * combination 1959 - * 1960 - * Due to the VHT Extended NSS Bandwidth Support, the maximum NSS can 1961 - * vary for a given BW/MCS. This function parses the data. 1962 - * 1963 - * Note: This function is exported by cfg80211. 1964 - */ 1965 - int ieee80211_get_vht_max_nss(struct ieee80211_vht_cap *cap, 1966 - enum ieee80211_vht_chanwidth bw, 1967 - int mcs, bool ext_nss_bw_capable, 1968 - unsigned int max_vht_nss); 1969 2047 1970 2048 /* 802.11ax HE MAC capabilities */ 1971 2049 #define IEEE80211_HE_MAC_CAP0_HTC_HE 0x01 ··· 3351 3559 WLAN_ACTION_SPCT_TPC_REQ = 2, 3352 3560 WLAN_ACTION_SPCT_TPC_RPRT = 3, 3353 3561 WLAN_ACTION_SPCT_CHL_SWITCH = 4, 3354 - }; 3355 - 3356 - /* VHT action codes */ 3357 - enum ieee80211_vht_actioncode { 3358 - WLAN_VHT_ACTION_COMPRESSED_BF = 0, 3359 - WLAN_VHT_ACTION_GROUPID_MGMT = 1, 3360 - WLAN_VHT_ACTION_OPMODE_NOTIF = 2, 3361 3562 }; 3362 3563 3363 3564 /* Self Protected Action codes */ ··· 5404 5619 #define NAN_DEV_CAPA_S3_SUPPORTED 0x10 5405 5620 5406 5621 #include "ieee80211-ht.h" 5622 + #include "ieee80211-vht.h" 5407 5623 #include "ieee80211-mesh.h" 5408 5624 5409 5625 #endif /* LINUX_IEEE80211_H */