aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMahesh Palivela <maheshp@posedge.com>2012-10-10 07:25:40 -0400
committerJohannes Berg <johannes.berg@intel.com>2012-10-17 05:02:13 -0400
commitd4950281d72d8845225e3a39dbeb366c40c824c9 (patch)
tree57396a72a205ed8d3b30993f6be44c7766b9722c
parent1258d97616fdca9abc0c21f2edeb1d5b21dcb128 (diff)
ieee80211: Rename VHT cap struct
Rename struct ieee80211_vht_capabilities to ieee80211_vht_cap and renamed its member vht_capabilities_info to vht_cap_info. Signed-off-by: Mahesh Palivela <maheshp@posedge.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r--include/linux/ieee80211.h45
-rw-r--r--net/mac80211/main.c2
-rw-r--r--net/mac80211/mlme.c4
-rw-r--r--net/mac80211/util.c4
4 files changed, 36 insertions, 19 deletions
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h
index 2385119f8bb..8c803f0e492 100644
--- a/include/linux/ieee80211.h
+++ b/include/linux/ieee80211.h
@@ -1107,20 +1107,6 @@ struct ieee80211_ht_operation {
1107#define WLAN_HT_SMPS_CONTROL_STATIC 1 1107#define WLAN_HT_SMPS_CONTROL_STATIC 1
1108#define WLAN_HT_SMPS_CONTROL_DYNAMIC 3 1108#define WLAN_HT_SMPS_CONTROL_DYNAMIC 3
1109 1109
1110#define VHT_MCS_SUPPORTED_SET_SIZE 8
1111
1112struct ieee80211_vht_capabilities {
1113 __le32 vht_capabilities_info;
1114 u8 vht_supported_mcs_set[VHT_MCS_SUPPORTED_SET_SIZE];
1115} __packed;
1116
1117struct ieee80211_vht_operation {
1118 u8 vht_op_info_chwidth;
1119 u8 vht_op_info_chan_center_freq_seg1_idx;
1120 u8 vht_op_info_chan_center_freq_seg2_idx;
1121 __le16 vht_basic_mcs_set;
1122} __packed;
1123
1124/** 1110/**
1125 * struct ieee80211_vht_mcs_info - VHT MCS information 1111 * struct ieee80211_vht_mcs_info - VHT MCS information
1126 * @rx_mcs_map: RX MCS map 2 bits for each stream, total 8 streams 1112 * @rx_mcs_map: RX MCS map 2 bits for each stream, total 8 streams
@@ -1141,6 +1127,37 @@ struct ieee80211_vht_mcs_info {
1141 __le16 tx_highest; 1127 __le16 tx_highest;
1142} __packed; 1128} __packed;
1143 1129
1130/**
1131 * struct ieee80211_vht_cap - VHT capabilities
1132 *
1133 * This structure is the "VHT capabilities element" as
1134 * described in 802.11ac D3.0 8.4.2.160
1135 * @vht_cap_info: VHT capability info
1136 * @supp_mcs: VHT MCS supported rates
1137 */
1138struct ieee80211_vht_cap {
1139 __le32 vht_cap_info;
1140 struct ieee80211_vht_mcs_info supp_mcs;
1141} __packed;
1142
1143/**
1144 * struct ieee80211_vht_operation - VHT operation IE
1145 *
1146 * This structure is the "VHT operation element" as
1147 * described in 802.11ac D3.0 8.4.2.161
1148 * @chan_width: Operating channel width
1149 * @center_freq_seg1_idx: center freq segment 1 index
1150 * @center_freq_seg2_idx: center freq segment 2 index
1151 * @basic_mcs_set: VHT Basic MCS rate set
1152 */
1153struct ieee80211_vht_operation {
1154 u8 chan_width;
1155 u8 center_freq_seg1_idx;
1156 u8 center_freq_seg2_idx;
1157 __le16 basic_mcs_set;
1158} __packed;
1159
1160
1144#define IEEE80211_VHT_MCS_ZERO_TO_SEVEN_SUPPORT 0 1161#define IEEE80211_VHT_MCS_ZERO_TO_SEVEN_SUPPORT 0
1145#define IEEE80211_VHT_MCS_ZERO_TO_EIGHT_SUPPORT 1 1162#define IEEE80211_VHT_MCS_ZERO_TO_EIGHT_SUPPORT 1
1146#define IEEE80211_VHT_MCS_ZERO_TO_NINE_SUPPORT 2 1163#define IEEE80211_VHT_MCS_ZERO_TO_NINE_SUPPORT 2
diff --git a/net/mac80211/main.c b/net/mac80211/main.c
index 473b755b349..620f427069c 100644
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -876,7 +876,7 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
876 876
877 if (supp_vht) 877 if (supp_vht)
878 local->scan_ies_len += 878 local->scan_ies_len +=
879 2 + sizeof(struct ieee80211_vht_capabilities); 879 2 + sizeof(struct ieee80211_vht_cap);
880 880
881 if (!local->ops->hw_scan) { 881 if (!local->ops->hw_scan) {
882 /* For hw_scan, driver needs to set these up. */ 882 /* For hw_scan, driver needs to set these up. */
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index f24884a6061..4af5a3eb892 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -353,7 +353,7 @@ static void ieee80211_add_vht_ie(struct ieee80211_sub_if_data *sdata,
353 cap = vht_cap.cap; 353 cap = vht_cap.cap;
354 354
355 /* reserve and fill IE */ 355 /* reserve and fill IE */
356 pos = skb_put(skb, sizeof(struct ieee80211_vht_capabilities) + 2); 356 pos = skb_put(skb, sizeof(struct ieee80211_vht_cap) + 2);
357 ieee80211_ie_build_vht_cap(pos, &vht_cap, cap); 357 ieee80211_ie_build_vht_cap(pos, &vht_cap, cap);
358} 358}
359 359
@@ -412,7 +412,7 @@ static void ieee80211_send_assoc(struct ieee80211_sub_if_data *sdata)
412 4 + /* power capability */ 412 4 + /* power capability */
413 2 + 2 * sband->n_channels + /* supported channels */ 413 2 + 2 * sband->n_channels + /* supported channels */
414 2 + sizeof(struct ieee80211_ht_cap) + /* HT */ 414 2 + sizeof(struct ieee80211_ht_cap) + /* HT */
415 2 + sizeof(struct ieee80211_vht_capabilities) + /* VHT */ 415 2 + sizeof(struct ieee80211_vht_cap) + /* VHT */
416 assoc_data->ie_len + /* extra IEs */ 416 assoc_data->ie_len + /* extra IEs */
417 9, /* WMM */ 417 9, /* WMM */
418 GFP_KERNEL); 418 GFP_KERNEL);
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index 558412d75ac..3dca9827624 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -1775,8 +1775,8 @@ u8 *ieee80211_ie_build_vht_cap(u8 *pos, struct ieee80211_sta_vht_cap *vht_cap,
1775 __le32 tmp; 1775 __le32 tmp;
1776 1776
1777 *pos++ = WLAN_EID_VHT_CAPABILITY; 1777 *pos++ = WLAN_EID_VHT_CAPABILITY;
1778 *pos++ = sizeof(struct ieee80211_vht_capabilities); 1778 *pos++ = sizeof(struct ieee80211_vht_cap);
1779 memset(pos, 0, sizeof(struct ieee80211_vht_capabilities)); 1779 memset(pos, 0, sizeof(struct ieee80211_vht_cap));
1780 1780
1781 /* capability flags */ 1781 /* capability flags */
1782 tmp = cpu_to_le32(cap); 1782 tmp = cpu_to_le32(cap);