Deleted Added
full compact
ieee80211_var.h (167242) ieee80211_var.h (167441)
1/*-
2 * Copyright (c) 2001 Atsushi Onoe
3 * Copyright (c) 2002-2005 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:

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

24 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 *
1/*-
2 * Copyright (c) 2001 Atsushi Onoe
3 * Copyright (c) 2002-2005 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:

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

24 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 *
32 * $FreeBSD: head/sys/net80211/ieee80211_var.h 167242 2007-03-05 18:52:35Z sam $
32 * $FreeBSD: head/sys/net80211/ieee80211_var.h 167441 2007-03-11 07:15:38Z sam $
33 */
34#ifndef _NET80211_IEEE80211_VAR_H_
35#define _NET80211_IEEE80211_VAR_H_
36
37/*
38 * Definitions for IEEE 802.11 drivers.
39 */
40#define IEEE80211_DEBUG

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

414#define ieee80211_msg_dumpradius(_ic) \
415 ((_ic)->ic_debug & IEEE80211_MSG_RADDUMP)
416#define ieee80211_msg_dumpradkeys(_ic) \
417 ((_ic)->ic_debug & IEEE80211_MSG_RADKEYS)
418#define ieee80211_msg_scan(_ic) \
419 ((_ic)->ic_debug & IEEE80211_MSG_SCAN)
420#define ieee80211_msg_assoc(_ic) \
421 ((_ic)->ic_debug & IEEE80211_MSG_ASSOC)
33 */
34#ifndef _NET80211_IEEE80211_VAR_H_
35#define _NET80211_IEEE80211_VAR_H_
36
37/*
38 * Definitions for IEEE 802.11 drivers.
39 */
40#define IEEE80211_DEBUG

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

414#define ieee80211_msg_dumpradius(_ic) \
415 ((_ic)->ic_debug & IEEE80211_MSG_RADDUMP)
416#define ieee80211_msg_dumpradkeys(_ic) \
417 ((_ic)->ic_debug & IEEE80211_MSG_RADKEYS)
418#define ieee80211_msg_scan(_ic) \
419 ((_ic)->ic_debug & IEEE80211_MSG_SCAN)
420#define ieee80211_msg_assoc(_ic) \
421 ((_ic)->ic_debug & IEEE80211_MSG_ASSOC)
422
423/*
424 * Emit a debug message about discarding a frame or information
425 * element. One format is for extracting the mac address from
426 * the frame header; the other is for when a header is not
427 * available or otherwise appropriate.
428 */
429#define IEEE80211_DISCARD(_ic, _m, _wh, _type, _fmt, ...) do { \
430 if ((_ic)->ic_debug & (_m)) \
431 ieee80211_discard_frame(_ic, _wh, _type, _fmt, __VA_ARGS__);\
432} while (0)
433#define IEEE80211_DISCARD_IE(_ic, _m, _wh, _type, _fmt, ...) do { \
434 if ((_ic)->ic_debug & (_m)) \
435 ieee80211_discard_ie(_ic, _wh, _type, _fmt, __VA_ARGS__);\
436} while (0)
437#define IEEE80211_DISCARD_MAC(_ic, _m, _mac, _type, _fmt, ...) do { \
438 if ((_ic)->ic_debug & (_m)) \
439 ieee80211_discard_mac(_ic, _mac, _type, _fmt, __VA_ARGS__);\
440} while (0)
441
442void ieee80211_discard_frame(struct ieee80211com *,
443 const struct ieee80211_frame *, const char *type, const char *fmt, ...);
444void ieee80211_discard_ie(struct ieee80211com *,
445 const struct ieee80211_frame *, const char *type, const char *fmt, ...);
446void ieee80211_discard_mac(struct ieee80211com *,
447 const u_int8_t mac[IEEE80211_ADDR_LEN], const char *type,
448 const char *fmt, ...);
422#else
423#define IEEE80211_DPRINTF(_ic, _m, _fmt, ...)
424#define IEEE80211_NOTE_FRAME(_ic, _m, _wh, _fmt, ...)
425#define IEEE80211_NOTE_MAC(_ic, _m, _mac, _fmt, ...)
426#define ieee80211_msg_dumppkts(_ic) 0
427#define ieee80211_msg(_ic, _m) 0
449#else
450#define IEEE80211_DPRINTF(_ic, _m, _fmt, ...)
451#define IEEE80211_NOTE_FRAME(_ic, _m, _wh, _fmt, ...)
452#define IEEE80211_NOTE_MAC(_ic, _m, _mac, _fmt, ...)
453#define ieee80211_msg_dumppkts(_ic) 0
454#define ieee80211_msg(_ic, _m) 0
455
456#define IEEE80211_DISCARD(_ic, _m, _wh, _type, _fmt, ...)
457#define IEEE80211_DISCARD_IE(_ic, _m, _wh, _type, _fmt, ...)
458#define IEEE80211_DISCARD_MAC(_ic, _m, _mac, _type, _fmt, ...)
428#endif
429
430#endif /* _NET80211_IEEE80211_VAR_H_ */
459#endif
460
461#endif /* _NET80211_IEEE80211_VAR_H_ */