Deleted Added
full compact
ieee80211_var.h (195379) ieee80211_var.h (195618)
1/*-
2 * Copyright (c) 2001 Atsushi Onoe
3 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 9 unchanged lines hidden (view full) ---

18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
1/*-
2 * Copyright (c) 2001 Atsushi Onoe
3 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 9 unchanged lines hidden (view full) ---

18 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
26 * $FreeBSD: head/sys/net80211/ieee80211_var.h 195379 2009-07-05 18:17:37Z sam $
26 * $FreeBSD: head/sys/net80211/ieee80211_var.h 195618 2009-07-11 15:02:45Z rpaulo $
27 */
28#ifndef _NET80211_IEEE80211_VAR_H_
29#define _NET80211_IEEE80211_VAR_H_
30
31/*
32 * Definitions for IEEE 802.11 drivers.
33 */
34/* NB: portability glue must go first */

--- 278 unchanged lines hidden (view full) ---

313 int batimeout, int baseqctl);
314 void (*ic_ampdu_rx_stop)(struct ieee80211_node *,
315 struct ieee80211_rx_ampdu *);
316 uint64_t ic_spare[8];
317};
318
319struct ieee80211_aclator;
320struct ieee80211_tdma_state;
27 */
28#ifndef _NET80211_IEEE80211_VAR_H_
29#define _NET80211_IEEE80211_VAR_H_
30
31/*
32 * Definitions for IEEE 802.11 drivers.
33 */
34/* NB: portability glue must go first */

--- 278 unchanged lines hidden (view full) ---

313 int batimeout, int baseqctl);
314 void (*ic_ampdu_rx_stop)(struct ieee80211_node *,
315 struct ieee80211_rx_ampdu *);
316 uint64_t ic_spare[8];
317};
318
319struct ieee80211_aclator;
320struct ieee80211_tdma_state;
321struct ieee80211_mesh_state;
322struct ieee80211_hwmp_state;
321
322struct ieee80211vap {
323 struct ifmedia iv_media; /* interface media config */
324 struct ifnet *iv_ifp; /* associated device */
325 struct bpf_if *iv_rawbpf; /* packet filter structure */
326 struct sysctl_ctx_list *iv_sysctl; /* dynamic sysctl context */
327 struct sysctl_oid *iv_oid; /* net.wlan.X sysctl oid */
328

--- 98 unchanged lines hidden (view full) ---

427
428 const struct ieee80211_authenticator *iv_auth; /* authenticator glue */
429 void *iv_ec; /* private auth state */
430
431 const struct ieee80211_aclator *iv_acl; /* acl glue */
432 void *iv_as; /* private aclator state */
433
434 struct ieee80211_tdma_state *iv_tdma; /* tdma state */
323
324struct ieee80211vap {
325 struct ifmedia iv_media; /* interface media config */
326 struct ifnet *iv_ifp; /* associated device */
327 struct bpf_if *iv_rawbpf; /* packet filter structure */
328 struct sysctl_ctx_list *iv_sysctl; /* dynamic sysctl context */
329 struct sysctl_oid *iv_oid; /* net.wlan.X sysctl oid */
330

--- 98 unchanged lines hidden (view full) ---

429
430 const struct ieee80211_authenticator *iv_auth; /* authenticator glue */
431 void *iv_ec; /* private auth state */
432
433 const struct ieee80211_aclator *iv_acl; /* acl glue */
434 void *iv_as; /* private aclator state */
435
436 struct ieee80211_tdma_state *iv_tdma; /* tdma state */
437 struct ieee80211_mesh_state *iv_mesh; /* MBSS state */
438 struct ieee80211_hwmp_state *iv_hwmp; /* HWMP state */
435
436 /* operate-mode detach hook */
437 void (*iv_opdetach)(struct ieee80211vap *);
438 /* receive processing */
439 int (*iv_input)(struct ieee80211_node *,
440 struct mbuf *, int, int);
441 void (*iv_recv_mgmt)(struct ieee80211_node *,
442 struct mbuf *, int, int, int);

--- 140 unchanged lines hidden (view full) ---

583#define IEEE80211_C_HOSTAP 0x00000400 /* CAPABILITY: HOSTAP avail */
584#define IEEE80211_C_AHDEMO 0x00000800 /* CAPABILITY: Old Adhoc Demo */
585#define IEEE80211_C_SWRETRY 0x00001000 /* CAPABILITY: sw tx retry */
586#define IEEE80211_C_TXPMGT 0x00002000 /* CAPABILITY: tx power mgmt */
587#define IEEE80211_C_SHSLOT 0x00004000 /* CAPABILITY: short slottime */
588#define IEEE80211_C_SHPREAMBLE 0x00008000 /* CAPABILITY: short preamble */
589#define IEEE80211_C_MONITOR 0x00010000 /* CAPABILITY: monitor mode */
590#define IEEE80211_C_DFS 0x00020000 /* CAPABILITY: DFS/radar avail*/
439
440 /* operate-mode detach hook */
441 void (*iv_opdetach)(struct ieee80211vap *);
442 /* receive processing */
443 int (*iv_input)(struct ieee80211_node *,
444 struct mbuf *, int, int);
445 void (*iv_recv_mgmt)(struct ieee80211_node *,
446 struct mbuf *, int, int, int);

--- 140 unchanged lines hidden (view full) ---

587#define IEEE80211_C_HOSTAP 0x00000400 /* CAPABILITY: HOSTAP avail */
588#define IEEE80211_C_AHDEMO 0x00000800 /* CAPABILITY: Old Adhoc Demo */
589#define IEEE80211_C_SWRETRY 0x00001000 /* CAPABILITY: sw tx retry */
590#define IEEE80211_C_TXPMGT 0x00002000 /* CAPABILITY: tx power mgmt */
591#define IEEE80211_C_SHSLOT 0x00004000 /* CAPABILITY: short slottime */
592#define IEEE80211_C_SHPREAMBLE 0x00008000 /* CAPABILITY: short preamble */
593#define IEEE80211_C_MONITOR 0x00010000 /* CAPABILITY: monitor mode */
594#define IEEE80211_C_DFS 0x00020000 /* CAPABILITY: DFS/radar avail*/
595#define IEEE80211_C_MBSS 0x00040000 /* CAPABILITY: MBSS available */
591/* 0x7c0000 available */
592#define IEEE80211_C_WPA1 0x00800000 /* CAPABILITY: WPA1 avail */
593#define IEEE80211_C_WPA2 0x01000000 /* CAPABILITY: WPA2 avail */
594#define IEEE80211_C_WPA 0x01800000 /* CAPABILITY: WPA1+WPA2 avail*/
595#define IEEE80211_C_BURST 0x02000000 /* CAPABILITY: frame bursting */
596#define IEEE80211_C_WME 0x04000000 /* CAPABILITY: WME avail */
597#define IEEE80211_C_WDS 0x08000000 /* CAPABILITY: 4-addr support */
598/* 0x10000000 reserved */
599#define IEEE80211_C_BGSCAN 0x20000000 /* CAPABILITY: bg scanning */
600#define IEEE80211_C_TXFRAG 0x40000000 /* CAPABILITY: tx fragments */
601#define IEEE80211_C_TDMA 0x80000000 /* CAPABILITY: TDMA avail */
602/* XXX protection/barker? */
603
604#define IEEE80211_C_OPMODE \
605 (IEEE80211_C_STA | IEEE80211_C_IBSS | IEEE80211_C_HOSTAP | \
606 IEEE80211_C_AHDEMO | IEEE80211_C_MONITOR | IEEE80211_C_WDS | \
596/* 0x7c0000 available */
597#define IEEE80211_C_WPA1 0x00800000 /* CAPABILITY: WPA1 avail */
598#define IEEE80211_C_WPA2 0x01000000 /* CAPABILITY: WPA2 avail */
599#define IEEE80211_C_WPA 0x01800000 /* CAPABILITY: WPA1+WPA2 avail*/
600#define IEEE80211_C_BURST 0x02000000 /* CAPABILITY: frame bursting */
601#define IEEE80211_C_WME 0x04000000 /* CAPABILITY: WME avail */
602#define IEEE80211_C_WDS 0x08000000 /* CAPABILITY: 4-addr support */
603/* 0x10000000 reserved */
604#define IEEE80211_C_BGSCAN 0x20000000 /* CAPABILITY: bg scanning */
605#define IEEE80211_C_TXFRAG 0x40000000 /* CAPABILITY: tx fragments */
606#define IEEE80211_C_TDMA 0x80000000 /* CAPABILITY: TDMA avail */
607/* XXX protection/barker? */
608
609#define IEEE80211_C_OPMODE \
610 (IEEE80211_C_STA | IEEE80211_C_IBSS | IEEE80211_C_HOSTAP | \
611 IEEE80211_C_AHDEMO | IEEE80211_C_MONITOR | IEEE80211_C_WDS | \
607 IEEE80211_C_TDMA)
612 IEEE80211_C_TDMA | IEEE80211_C_MBSS)
608
609#define IEEE80211_C_BITS \
610 "\20\1STA\002803ENCAP\7FF\10TURBOP\11IBSS\12PMGT" \
611 "\13HOSTAP\14AHDEMO\15SWRETRY\16TXPMGT\17SHSLOT\20SHPREAMBLE" \
613
614#define IEEE80211_C_BITS \
615 "\20\1STA\002803ENCAP\7FF\10TURBOP\11IBSS\12PMGT" \
616 "\13HOSTAP\14AHDEMO\15SWRETRY\16TXPMGT\17SHSLOT\20SHPREAMBLE" \
612 "\21MONITOR\22DFS\30WPA1\31WPA2\32BURST\33WME\34WDS\36BGSCAN" \
617 "\21MONITOR\22DFS\23MBSS\30WPA1\31WPA2\32BURST\33WME\34WDS\36BGSCAN" \
613 "\37TXFRAG\40TDMA"
614
615/*
616 * ic_htcaps/iv_htcaps: HT-specific device/driver capabilities
617 *
618 * NB: the low 16-bits are the 802.11 definitions, the upper
619 * 16-bits are used to define s/w/driver capabilities.
620 */

--- 157 unchanged lines hidden (view full) ---

778/*
779 * Debugging facilities compiled in when IEEE80211_DEBUG is defined.
780 *
781 * The intent is that any problem in the net80211 layer can be
782 * diagnosed by inspecting the statistics (dumped by the wlanstats
783 * program) and/or the msgs generated by net80211. Messages are
784 * broken into functional classes and can be controlled with the
785 * wlandebug program. Certain of these msg groups are for facilities
618 "\37TXFRAG\40TDMA"
619
620/*
621 * ic_htcaps/iv_htcaps: HT-specific device/driver capabilities
622 *
623 * NB: the low 16-bits are the 802.11 definitions, the upper
624 * 16-bits are used to define s/w/driver capabilities.
625 */

--- 157 unchanged lines hidden (view full) ---

783/*
784 * Debugging facilities compiled in when IEEE80211_DEBUG is defined.
785 *
786 * The intent is that any problem in the net80211 layer can be
787 * diagnosed by inspecting the statistics (dumped by the wlanstats
788 * program) and/or the msgs generated by net80211. Messages are
789 * broken into functional classes and can be controlled with the
790 * wlandebug program. Certain of these msg groups are for facilities
786 * that are no longer part of net80211 (e.g. IEEE80211_MSG_DOT1X).
791 * that are no longer part of net80211 (e.g. IEEE80211_MSG_DOT1XSM).
787 */
788#define IEEE80211_MSG_11N 0x80000000 /* 11n mode debug */
789#define IEEE80211_MSG_DEBUG 0x40000000 /* IFF_DEBUG equivalent */
790#define IEEE80211_MSG_DUMPPKTS 0x20000000 /* IFF_LINK2 equivalant */
791#define IEEE80211_MSG_CRYPTO 0x10000000 /* crypto work */
792#define IEEE80211_MSG_INPUT 0x08000000 /* input handling */
793#define IEEE80211_MSG_XRATE 0x04000000 /* rate set handling */
794#define IEEE80211_MSG_ELEMID 0x02000000 /* element id parsing */
795#define IEEE80211_MSG_NODE 0x01000000 /* node handling */
796#define IEEE80211_MSG_ASSOC 0x00800000 /* association handling */
797#define IEEE80211_MSG_AUTH 0x00400000 /* authentication handling */
798#define IEEE80211_MSG_SCAN 0x00200000 /* scanning */
799#define IEEE80211_MSG_OUTPUT 0x00100000 /* output handling */
800#define IEEE80211_MSG_STATE 0x00080000 /* state machine */
801#define IEEE80211_MSG_POWER 0x00040000 /* power save handling */
792 */
793#define IEEE80211_MSG_11N 0x80000000 /* 11n mode debug */
794#define IEEE80211_MSG_DEBUG 0x40000000 /* IFF_DEBUG equivalent */
795#define IEEE80211_MSG_DUMPPKTS 0x20000000 /* IFF_LINK2 equivalant */
796#define IEEE80211_MSG_CRYPTO 0x10000000 /* crypto work */
797#define IEEE80211_MSG_INPUT 0x08000000 /* input handling */
798#define IEEE80211_MSG_XRATE 0x04000000 /* rate set handling */
799#define IEEE80211_MSG_ELEMID 0x02000000 /* element id parsing */
800#define IEEE80211_MSG_NODE 0x01000000 /* node handling */
801#define IEEE80211_MSG_ASSOC 0x00800000 /* association handling */
802#define IEEE80211_MSG_AUTH 0x00400000 /* authentication handling */
803#define IEEE80211_MSG_SCAN 0x00200000 /* scanning */
804#define IEEE80211_MSG_OUTPUT 0x00100000 /* output handling */
805#define IEEE80211_MSG_STATE 0x00080000 /* state machine */
806#define IEEE80211_MSG_POWER 0x00040000 /* power save handling */
802#define IEEE80211_MSG_DOT1X 0x00020000 /* 802.1x authenticator */
807#define IEEE80211_MSG_HWMP 0x00020000 /* hybrid mesh protocol */
803#define IEEE80211_MSG_DOT1XSM 0x00010000 /* 802.1x state machine */
804#define IEEE80211_MSG_RADIUS 0x00008000 /* 802.1x radius client */
805#define IEEE80211_MSG_RADDUMP 0x00004000 /* dump 802.1x radius packets */
806#define IEEE80211_MSG_MESH 0x00002000 /* mesh networking */
807#define IEEE80211_MSG_WPA 0x00001000 /* WPA/RSN protocol */
808#define IEEE80211_MSG_ACL 0x00000800 /* ACL handling */
809#define IEEE80211_MSG_WME 0x00000400 /* WME protocol */
810#define IEEE80211_MSG_SUPERG 0x00000200 /* Atheros SuperG protocol */

--- 5 unchanged lines hidden (view full) ---

816#define IEEE80211_MSG_WDS 0x00000008 /* WDS handling */
817#define IEEE80211_MSG_IOCTL 0x00000004 /* ioctl handling */
818#define IEEE80211_MSG_TDMA 0x00000002 /* TDMA handling */
819
820#define IEEE80211_MSG_ANY 0xffffffff /* anything */
821
822#define IEEE80211_MSG_BITS \
823 "\20\2TDMA\3IOCTL\4WDS\5ACTION\6RATECTL\7ROAM\10INACT\11DOTH\12SUPERG" \
808#define IEEE80211_MSG_DOT1XSM 0x00010000 /* 802.1x state machine */
809#define IEEE80211_MSG_RADIUS 0x00008000 /* 802.1x radius client */
810#define IEEE80211_MSG_RADDUMP 0x00004000 /* dump 802.1x radius packets */
811#define IEEE80211_MSG_MESH 0x00002000 /* mesh networking */
812#define IEEE80211_MSG_WPA 0x00001000 /* WPA/RSN protocol */
813#define IEEE80211_MSG_ACL 0x00000800 /* ACL handling */
814#define IEEE80211_MSG_WME 0x00000400 /* WME protocol */
815#define IEEE80211_MSG_SUPERG 0x00000200 /* Atheros SuperG protocol */

--- 5 unchanged lines hidden (view full) ---

821#define IEEE80211_MSG_WDS 0x00000008 /* WDS handling */
822#define IEEE80211_MSG_IOCTL 0x00000004 /* ioctl handling */
823#define IEEE80211_MSG_TDMA 0x00000002 /* TDMA handling */
824
825#define IEEE80211_MSG_ANY 0xffffffff /* anything */
826
827#define IEEE80211_MSG_BITS \
828 "\20\2TDMA\3IOCTL\4WDS\5ACTION\6RATECTL\7ROAM\10INACT\11DOTH\12SUPERG" \
824 "\13WME\14ACL\15WPA\16RADKEYS\17RADDUMP\20RADIUS\21DOT1XSM\22DOT1X" \
829 "\13WME\14ACL\15WPA\16RADKEYS\17RADDUMP\20RADIUS\21DOT1XSM\22HWMP" \
825 "\23POWER\24STATE\25OUTPUT\26SCAN\27AUTH\30ASSOC\31NODE\32ELEMID" \
826 "\33XRATE\34INPUT\35CRYPTO\36DUPMPKTS\37DEBUG\04011N"
827
828#ifdef IEEE80211_DEBUG
829#define ieee80211_msg(_vap, _m) ((_vap)->iv_debug & (_m))
830#define IEEE80211_DPRINTF(_vap, _m, _fmt, ...) do { \
831 if (ieee80211_msg(_vap, _m)) \
832 ieee80211_note(_vap, _fmt, __VA_ARGS__); \

--- 75 unchanged lines hidden ---
830 "\23POWER\24STATE\25OUTPUT\26SCAN\27AUTH\30ASSOC\31NODE\32ELEMID" \
831 "\33XRATE\34INPUT\35CRYPTO\36DUPMPKTS\37DEBUG\04011N"
832
833#ifdef IEEE80211_DEBUG
834#define ieee80211_msg(_vap, _m) ((_vap)->iv_debug & (_m))
835#define IEEE80211_DPRINTF(_vap, _m, _fmt, ...) do { \
836 if (ieee80211_msg(_vap, _m)) \
837 ieee80211_note(_vap, _fmt, __VA_ARGS__); \

--- 75 unchanged lines hidden ---