[PATCH 03/19] defs: Add measurement and neighbor report definitions

Ilan Peer ilan.peer at intel.com
Tue Apr 5 06:07:56 PDT 2016


From: David Spinadel <david.spinadel at intel.com>

Add measurement report definitions from table 8-80 in IEEE Std 802.11 MC
D4.3 "Measurement type definition for measurement requests".

Add measurement report definitions from IEEE Std 802.11 2012 table 8-71
"Location subject definition".

Add neighbor report bandwidth subelement definition from IEEE Std 802.11
MC D4.3 table 8-149 - "Optional subelement IDs neighbor report"

Add neighbor report channel width definition from 802.11 MC D4.3,
table 8-151 - "HT/VHT Operation Information subfields".

Add definitions for neighbor report BSSID info from 802.11 MC D4.3,
chapter 8.4.2.36 "Neighbor Report element".

Signed-off-by: David Spinadel <david.spinadel at intel.com>
---
 src/common/ieee802_11_defs.h | 67 ++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 67 insertions(+)

diff --git a/src/common/ieee802_11_defs.h b/src/common/ieee802_11_defs.h
index e1a8ef7..0b63328 100644
--- a/src/common/ieee802_11_defs.h
+++ b/src/common/ieee802_11_defs.h
@@ -453,6 +453,47 @@ enum nai_realm_eap_cred_type {
 	NAI_REALM_CRED_TYPE_VENDOR_SPECIFIC = 10
 };
 
+/* From IEEE Std 802.11 MC D4.3 table 8-80 - Measurement type definitions for
+ * measurement requests.
+ */
+enum measure_type {
+	MEASURE_TYPE_BASIC = 0,
+	MEASURE_TYPE_CCA = 1,
+	MEASURE_TYPE_RPI_HIST = 2,
+	MEASURE_TYPE_CHANNEL_LOAD = 3,
+	MEASURE_TYPE_NOISE_HIST = 4,
+	MEASURE_TYPE_BEACON = 5,
+	MEASURE_TYPE_FRAME = 6,
+	MEASURE_TYPE_STA_STATISTICS = 7,
+	MEASURE_TYPE_LCI = 8,
+	MEASURE_TYPE_TRANSMIT_STREAM = 9,
+	MEASURE_TYPE_MULTICAST_DIAG = 10,
+	MEASURE_TYPE_LOCATION_CIVIC = 11,
+	MEASURE_TYPE_LOCATION_ID = 12,
+	MEASURE_TYPE_DIRECTIONAL_CHAN_QUALITY = 13,
+	MEASURE_TYPE_DIRECTIONAL_MEASURE = 14,
+	MEASURE_TYPE_DIRECTIONAL_STATS = 15,
+	MEASURE_TYPE_FTM_RANGE = 16,
+	MEASURE_TYPE_MEASURE_PAUSE = 255,
+};
+
+/* From IEEE Std 802.11 2012 table 8-71 - Location subject definition */
+enum location_subject {
+	LOCATION_SUBJECT_LOCAL		= 0,
+	LOCATION_SUBJECT_REMOTE		= 1,
+	LOCATION_SUBJECT_3RD_PARTY	= 2,
+};
+
+/* From IEEE Std 802.11 MC D4.3 table 8-93 - Optional subelement IDs for LCI
+ * request.
+ */
+#define LCI_REQ_SUBELEMENT_MAX_AGE 4
+
+/* From IEEE Std 802.11 MC D4.3 table 8-149 - Optional subelement IDs for
+ * neighbor report
+ */
+#define NEIGHBOR_REPORT_BANDWIDTH 6
+
 #ifdef _MSC_VER
 #pragma pack(push, 1)
 #endif /* _MSC_VER */
@@ -1558,4 +1599,30 @@ enum phy_type {
 #define NEI_REP_BSSID_INFO_MOBILITY_DOMAIN BIT(10)
 #define NEI_REP_BSSID_INFO_HT BIT(11)
 
+/* From IEEE Std 802.11 MC D4.3, chapter 8.4.2.36 "Neighbor Report element" */
+#define	NEI_REP_BSSID_INFO_SECURITY BIT(2)
+#define	NEI_REP_BSSID_INFO_KEY_SCOPE BIT(3)
+#define	NEI_REP_BSSID_INFO_SPECTRUM_MGMT BIT(4)
+#define	NEI_REP_BSSID_INFO_QOS BIT(5)
+#define	NEI_REP_BSSID_INFO_APSD BIT(6)
+#define	NEI_REP_BSSID_INFO_RM BIT(7)
+#define	NEI_REP_BSSID_INFO_DELAYED_BA BIT(8)
+#define	NEI_REP_BSSID_INFO_IMM_BA BIT(9)
+#define	NEI_REP_BSSID_INFO_MOBILITY_DOMAIN BIT(10)
+#define	NEI_REP_BSSID_INFO_HT BIT(11)
+#define	NEI_REP_BSSID_INFO_VHT BIT(12)
+#define	NEI_REP_BSSID_INFO_FTM BIT(13)
+
+/* From IEEE Std 802.11 MC D4.3 table 8-151 - HT/VHT Operation Information
+ * subfields.
+ * Note: These definitions are not the same as other VHT_CHANWIDTH_*.
+ */
+enum nr_chan_width {
+	NR_CHAN_WIDTH_20 = 0,
+	NR_CHAN_WIDTH_40 = 1,
+	NR_CHAN_WIDTH_80 = 2,
+	NR_CHAN_WIDTH_160 = 3,
+	NR_CHAN_WIDTH_80P80 = 4,
+};
+
 #endif /* IEEE802_11_DEFS_H */
-- 
1.9.1




More information about the Hostap mailing list