aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2014-09-08 19:43:58 -0400
committerDavid S. Miller <davem@davemloft.net>2014-09-08 19:43:58 -0400
commit5b4c314575ea6edd57c547c2123083d88d8ff4e6 (patch)
treec3149c5f8c99b36a631d9776a3bb5541d217a0bb /include/linux
parenta7f26b7e1ee73ac9e766c430fea5af658d839954 (diff)
parent61a3d4f9d52c00b2016bc27fc66b10a194043f76 (diff)
Merge tag 'master-2014-09-08' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next
John W. Linville says: ==================== pull request: wireless-next 2014-09-08 Please pull this batch of updates intended for the 3.18 stream... For the mac80211 bits, Johannes says: "Not that much content this time. Some RCU cleanups, crypto performance improvements, and various patches all over, rather than listing them one might as well look into the git log instead." For the Bluetooth bits, Gustavo says: "The changes consists of: - Coding style fixes to HCI drivers - Corrupted ack value fix for the H5 HCI driver - A couple of Enhanced L2CAP fixes - Conversion of SMP code to use common L2CAP channel API - Page scan optimizations when using the kernel-side whitelist - Various mac802154 and and ieee802154 6lowpan cleanups - One new Atheros USB ID" For the iwlwifi bits, Emmanuel says: "We have a new big thing coming up which is called Dynamic Queue Allocation (or DQA). This is a completely new way to work with the Tx queues and it requires major refactoring. This is being done by Johannes and Avri. Besides this, Johannes disables U-APSD by default because of APs that would disable A-MPDU if the association supports U-ASPD. Luca contributed to the power area which he was cleaning up on the way while working on CSA. A few more random things here and there." For the Atheros bits, Kalle says: "For ath6kl we had two small fixes and a new SDIO device id. For ath10k the bigger changes are: * support for new firmware version 10.2 (Michal) * spectral scan support (Simon, Sven & Mathias) * export a firmware crash dump file (Ben & me) * cleaning up of pci.c (Michal) * print pci id in all messages, which causes most of the churn (Michal)" Beyond that, we have the usual collection of various updates to ath9k, b43, mwifiex, and wil6210, as well as a few other bits here and there. Please let me know if there are problems! ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/bcma/bcma_regs.h5
-rw-r--r--include/linux/ieee80211.h65
2 files changed, 70 insertions, 0 deletions
diff --git a/include/linux/bcma/bcma_regs.h b/include/linux/bcma/bcma_regs.h
index 917dcd7965e7..e64ae7bf80a1 100644
--- a/include/linux/bcma/bcma_regs.h
+++ b/include/linux/bcma/bcma_regs.h
@@ -39,6 +39,11 @@
39#define BCMA_RESET_CTL_RESET 0x0001 39#define BCMA_RESET_CTL_RESET 0x0001
40#define BCMA_RESET_ST 0x0804 40#define BCMA_RESET_ST 0x0804
41 41
42#define BCMA_NS_ROM_IOST_BOOT_DEV_MASK 0x0003
43#define BCMA_NS_ROM_IOST_BOOT_DEV_NOR 0x0000
44#define BCMA_NS_ROM_IOST_BOOT_DEV_NAND 0x0001
45#define BCMA_NS_ROM_IOST_BOOT_DEV_ROM 0x0002
46
42/* BCMA PCI config space registers. */ 47/* BCMA PCI config space registers. */
43#define BCMA_PCI_PMCSR 0x44 48#define BCMA_PCI_PMCSR 0x44
44#define BCMA_PCI_PE 0x100 49#define BCMA_PCI_PE 0x100
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h
index 63ab3873c5ed..8018c915ee63 100644
--- a/include/linux/ieee80211.h
+++ b/include/linux/ieee80211.h
@@ -838,6 +838,16 @@ enum ieee80211_vht_opmode_bits {
838 838
839#define WLAN_SA_QUERY_TR_ID_LEN 2 839#define WLAN_SA_QUERY_TR_ID_LEN 2
840 840
841/**
842 * struct ieee80211_tpc_report_ie
843 *
844 * This structure refers to "TPC Report element"
845 */
846struct ieee80211_tpc_report_ie {
847 u8 tx_power;
848 u8 link_margin;
849} __packed;
850
841struct ieee80211_mgmt { 851struct ieee80211_mgmt {
842 __le16 frame_control; 852 __le16 frame_control;
843 __le16 duration; 853 __le16 duration;
@@ -973,6 +983,13 @@ struct ieee80211_mgmt {
973 u8 action_code; 983 u8 action_code;
974 u8 operating_mode; 984 u8 operating_mode;
975 } __packed vht_opmode_notif; 985 } __packed vht_opmode_notif;
986 struct {
987 u8 action_code;
988 u8 dialog_token;
989 u8 tpc_elem_id;
990 u8 tpc_elem_length;
991 struct ieee80211_tpc_report_ie tpc;
992 } __packed tpc_report;
976 } u; 993 } u;
977 } __packed action; 994 } __packed action;
978 } u; 995 } u;
@@ -1865,6 +1882,7 @@ enum ieee80211_category {
1865 WLAN_CATEGORY_DLS = 2, 1882 WLAN_CATEGORY_DLS = 2,
1866 WLAN_CATEGORY_BACK = 3, 1883 WLAN_CATEGORY_BACK = 3,
1867 WLAN_CATEGORY_PUBLIC = 4, 1884 WLAN_CATEGORY_PUBLIC = 4,
1885 WLAN_CATEGORY_RADIO_MEASUREMENT = 5,
1868 WLAN_CATEGORY_HT = 7, 1886 WLAN_CATEGORY_HT = 7,
1869 WLAN_CATEGORY_SA_QUERY = 8, 1887 WLAN_CATEGORY_SA_QUERY = 8,
1870 WLAN_CATEGORY_PROTECTED_DUAL_OF_ACTION = 9, 1888 WLAN_CATEGORY_PROTECTED_DUAL_OF_ACTION = 9,
@@ -2378,4 +2396,51 @@ static inline bool ieee80211_check_tim(const struct ieee80211_tim_ie *tim,
2378#define TU_TO_JIFFIES(x) (usecs_to_jiffies((x) * 1024)) 2396#define TU_TO_JIFFIES(x) (usecs_to_jiffies((x) * 1024))
2379#define TU_TO_EXP_TIME(x) (jiffies + TU_TO_JIFFIES(x)) 2397#define TU_TO_EXP_TIME(x) (jiffies + TU_TO_JIFFIES(x))
2380 2398
2399/**
2400 * ieee80211_action_contains_tpc - checks if the frame contains TPC element
2401 * @skb: the skb containing the frame, length will be checked
2402 *
2403 * This function checks if it's either TPC report action frame or Link
2404 * Measurement report action frame as defined in IEEE Std. 802.11-2012 8.5.2.5
2405 * and 8.5.7.5 accordingly.
2406 */
2407static inline bool ieee80211_action_contains_tpc(struct sk_buff *skb)
2408{
2409 struct ieee80211_mgmt *mgmt = (void *)skb->data;
2410
2411 if (!ieee80211_is_action(mgmt->frame_control))
2412 return false;
2413
2414 if (skb->len < IEEE80211_MIN_ACTION_SIZE +
2415 sizeof(mgmt->u.action.u.tpc_report))
2416 return false;
2417
2418 /*
2419 * TPC report - check that:
2420 * category = 0 (Spectrum Management) or 5 (Radio Measurement)
2421 * spectrum management action = 3 (TPC/Link Measurement report)
2422 * TPC report EID = 35
2423 * TPC report element length = 2
2424 *
2425 * The spectrum management's tpc_report struct is used here both for
2426 * parsing tpc_report and radio measurement's link measurement report
2427 * frame, since the relevant part is identical in both frames.
2428 */
2429 if (mgmt->u.action.category != WLAN_CATEGORY_SPECTRUM_MGMT &&
2430 mgmt->u.action.category != WLAN_CATEGORY_RADIO_MEASUREMENT)
2431 return false;
2432
2433 /* both spectrum mgmt and link measurement have same action code */
2434 if (mgmt->u.action.u.tpc_report.action_code !=
2435 WLAN_ACTION_SPCT_TPC_RPRT)
2436 return false;
2437
2438 if (mgmt->u.action.u.tpc_report.tpc_elem_id != WLAN_EID_TPC_REPORT ||
2439 mgmt->u.action.u.tpc_report.tpc_elem_length !=
2440 sizeof(struct ieee80211_tpc_report_ie))
2441 return false;
2442
2443 return true;
2444}
2445
2381#endif /* LINUX_IEEE80211_H */ 2446#endif /* LINUX_IEEE80211_H */