aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2013-02-21 11:36:01 -0500
committerJohannes Berg <johannes.berg@intel.com>2013-03-06 10:35:47 -0500
commitee2aca343c9aa64d277a75a5df043299dc84cfd9 (patch)
tree697ac55d4d0119e97ead3a530ebac8cf37922f78 /include
parentc8bb93f5f5d478a01db66127844d1d2dd30abec7 (diff)
cfg80211: add ability to override VHT capabilities
For testing it's sometimes useful to be able to override certain VHT capability advertisement, add the ability to do that in cfg80211. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'include')
-rw-r--r--include/net/cfg80211.h12
-rw-r--r--include/uapi/linux/nl80211.h3
2 files changed, 15 insertions, 0 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index ed2b08da3b93..73a523901c73 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -1430,9 +1430,11 @@ struct cfg80211_auth_request {
1430 * enum cfg80211_assoc_req_flags - Over-ride default behaviour in association. 1430 * enum cfg80211_assoc_req_flags - Over-ride default behaviour in association.
1431 * 1431 *
1432 * @ASSOC_REQ_DISABLE_HT: Disable HT (802.11n) 1432 * @ASSOC_REQ_DISABLE_HT: Disable HT (802.11n)
1433 * @ASSOC_REQ_DISABLE_VHT: Disable VHT
1433 */ 1434 */
1434enum cfg80211_assoc_req_flags { 1435enum cfg80211_assoc_req_flags {
1435 ASSOC_REQ_DISABLE_HT = BIT(0), 1436 ASSOC_REQ_DISABLE_HT = BIT(0),
1437 ASSOC_REQ_DISABLE_VHT = BIT(1),
1436}; 1438};
1437 1439
1438/** 1440/**
@@ -1454,6 +1456,8 @@ enum cfg80211_assoc_req_flags {
1454 * @ht_capa: HT Capabilities over-rides. Values set in ht_capa_mask 1456 * @ht_capa: HT Capabilities over-rides. Values set in ht_capa_mask
1455 * will be used in ht_capa. Un-supported values will be ignored. 1457 * will be used in ht_capa. Un-supported values will be ignored.
1456 * @ht_capa_mask: The bits of ht_capa which are to be used. 1458 * @ht_capa_mask: The bits of ht_capa which are to be used.
1459 * @vht_capa: VHT capability override
1460 * @vht_capa_mask: VHT capability mask indicating which fields to use
1457 */ 1461 */
1458struct cfg80211_assoc_request { 1462struct cfg80211_assoc_request {
1459 struct cfg80211_bss *bss; 1463 struct cfg80211_bss *bss;
@@ -1464,6 +1468,7 @@ struct cfg80211_assoc_request {
1464 u32 flags; 1468 u32 flags;
1465 struct ieee80211_ht_cap ht_capa; 1469 struct ieee80211_ht_cap ht_capa;
1466 struct ieee80211_ht_cap ht_capa_mask; 1470 struct ieee80211_ht_cap ht_capa_mask;
1471 struct ieee80211_vht_cap vht_capa, vht_capa_mask;
1467}; 1472};
1468 1473
1469/** 1474/**
@@ -1574,6 +1579,8 @@ struct cfg80211_ibss_params {
1574 * @ht_capa: HT Capabilities over-rides. Values set in ht_capa_mask 1579 * @ht_capa: HT Capabilities over-rides. Values set in ht_capa_mask
1575 * will be used in ht_capa. Un-supported values will be ignored. 1580 * will be used in ht_capa. Un-supported values will be ignored.
1576 * @ht_capa_mask: The bits of ht_capa which are to be used. 1581 * @ht_capa_mask: The bits of ht_capa which are to be used.
1582 * @vht_capa: VHT Capability overrides
1583 * @vht_capa_mask: The bits of vht_capa which are to be used.
1577 */ 1584 */
1578struct cfg80211_connect_params { 1585struct cfg80211_connect_params {
1579 struct ieee80211_channel *channel; 1586 struct ieee80211_channel *channel;
@@ -1592,6 +1599,8 @@ struct cfg80211_connect_params {
1592 int bg_scan_period; 1599 int bg_scan_period;
1593 struct ieee80211_ht_cap ht_capa; 1600 struct ieee80211_ht_cap ht_capa;
1594 struct ieee80211_ht_cap ht_capa_mask; 1601 struct ieee80211_ht_cap ht_capa_mask;
1602 struct ieee80211_vht_cap vht_capa;
1603 struct ieee80211_vht_cap vht_capa_mask;
1595}; 1604};
1596 1605
1597/** 1606/**
@@ -2516,6 +2525,8 @@ struct wiphy_wowlan_support {
2516 * @ap_sme_capa: AP SME capabilities, flags from &enum nl80211_ap_sme_features. 2525 * @ap_sme_capa: AP SME capabilities, flags from &enum nl80211_ap_sme_features.
2517 * @ht_capa_mod_mask: Specify what ht_cap values can be over-ridden. 2526 * @ht_capa_mod_mask: Specify what ht_cap values can be over-ridden.
2518 * If null, then none can be over-ridden. 2527 * If null, then none can be over-ridden.
2528 * @vht_capa_mod_mask: Specify what VHT capabilities can be over-ridden.
2529 * If null, then none can be over-ridden.
2519 * 2530 *
2520 * @max_acl_mac_addrs: Maximum number of MAC addresses that the device 2531 * @max_acl_mac_addrs: Maximum number of MAC addresses that the device
2521 * supports for ACL. 2532 * supports for ACL.
@@ -2624,6 +2635,7 @@ struct wiphy {
2624 struct dentry *debugfsdir; 2635 struct dentry *debugfsdir;
2625 2636
2626 const struct ieee80211_ht_cap *ht_capa_mod_mask; 2637 const struct ieee80211_ht_cap *ht_capa_mod_mask;
2638 const struct ieee80211_vht_cap *vht_capa_mod_mask;
2627 2639
2628#ifdef CONFIG_NET_NS 2640#ifdef CONFIG_NET_NS
2629 /* the network namespace this phy lives in currently */ 2641 /* the network namespace this phy lives in currently */
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 9844c10a2999..2c3e88360037 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -1685,6 +1685,9 @@ enum nl80211_attrs {
1685 NL80211_ATTR_PROTOCOL_FEATURES, 1685 NL80211_ATTR_PROTOCOL_FEATURES,
1686 NL80211_ATTR_SPLIT_WIPHY_DUMP, 1686 NL80211_ATTR_SPLIT_WIPHY_DUMP,
1687 1687
1688 NL80211_ATTR_DISABLE_VHT,
1689 NL80211_ATTR_VHT_CAPABILITY_MASK,
1690
1688 /* add attributes here, update the policy in nl80211.c */ 1691 /* add attributes here, update the policy in nl80211.c */
1689 1692
1690 __NL80211_ATTR_AFTER_LAST, 1693 __NL80211_ATTR_AFTER_LAST,