summaryrefslogtreecommitdiff
path: root/src/transport/ieee80211_radiotap.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/transport/ieee80211_radiotap.h')
-rw-r--r--src/transport/ieee80211_radiotap.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/transport/ieee80211_radiotap.h b/src/transport/ieee80211_radiotap.h
index f05449f18..9bdfa02f5 100644
--- a/src/transport/ieee80211_radiotap.h
+++ b/src/transport/ieee80211_radiotap.h
@@ -61,7 +61,8 @@
61 * The radio capture header precedes the 802.11 header. 61 * The radio capture header precedes the 802.11 header.
62 * All data in the header is little endian on all platforms. 62 * All data in the header is little endian on all platforms.
63 */ 63 */
64struct ieee80211_radiotap_header { 64struct ieee80211_radiotap_header
65{
65 u8 it_version; /* Version 0. Only increases 66 u8 it_version; /* Version 0. Only increases
66 * for drastic changes, 67 * for drastic changes,
67 * introduction of compatible 68 * introduction of compatible
@@ -179,7 +180,8 @@ struct ieee80211_radiotap_header {
179 * Number of unicast retries a transmitted frame used. 180 * Number of unicast retries a transmitted frame used.
180 * 181 *
181 */ 182 */
182enum ieee80211_radiotap_type { 183enum ieee80211_radiotap_type
184{
183 IEEE80211_RADIOTAP_TSFT = 0, 185 IEEE80211_RADIOTAP_TSFT = 0,
184 IEEE80211_RADIOTAP_FLAGS = 1, 186 IEEE80211_RADIOTAP_FLAGS = 1,
185 IEEE80211_RADIOTAP_RATE = 2, 187 IEEE80211_RADIOTAP_RATE = 2,
@@ -255,19 +257,19 @@ enum ieee80211_radiotap_type {
255 257
256/* helpers */ 258/* helpers */
257static inline u16 259static inline u16
258get_unaligned_le16(const u8 *p) 260get_unaligned_le16 (const u8 *p)
259{ 261{
260 return p[0] | p[1] << 8; 262 return p[0] | p[1] << 8;
261} 263}
262 264
263 265
264static inline int 266static inline int
265ieee80211_get_radiotap_len(unsigned char *data) 267ieee80211_get_radiotap_len (unsigned char *data)
266{ 268{
267 struct ieee80211_radiotap_header *hdr = 269 struct ieee80211_radiotap_header *hdr =
268 (struct ieee80211_radiotap_header *)data; 270 (struct ieee80211_radiotap_header *) data;
269 271
270 return get_unaligned_le16((const u8 *)&hdr->it_len); 272 return get_unaligned_le16 ((const u8 *) &hdr->it_len);
271} 273}
272 274
273#endif /* IEEE80211_RADIOTAP_H */ 275#endif /* IEEE80211_RADIOTAP_H */