wl_dbg.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * Minimal debug/trace/assert driver definitions for
  3. * Broadcom 802.11 Networking Adapter.
  4. *
  5. * Copyright (C) 1999-2014, Broadcom Corporation
  6. *
  7. * Unless you and Broadcom execute a separate written software license
  8. * agreement governing use of this software, this software is licensed to you
  9. * under the terms of the GNU General Public License version 2 (the "GPL"),
  10. * available at http://www.broadcom.com/licenses/GPLv2.php, with the
  11. * following added to such license:
  12. *
  13. * As a special exception, the copyright holders of this software give you
  14. * permission to link this software with independent modules, and to copy and
  15. * distribute the resulting executable under terms of your choice, provided that
  16. * you also meet, for each linked independent module, the terms and conditions of
  17. * the license of that module. An independent module is a module which is not
  18. * derived from this software. The special exception does not apply to any
  19. * modifications of the software.
  20. *
  21. * Notwithstanding the above, under no circumstances may you combine this
  22. * software in any way with any other Broadcom software provided under a license
  23. * other than the GPL, without Broadcom's express prior written consent.
  24. *
  25. * $Id: wl_dbg.h 430628 2013-10-19 04:07:25Z $
  26. */
  27. #ifndef _wl_dbg_h_
  28. #define _wl_dbg_h_
  29. /* wl_msg_level is a bit vector with defs in wlioctl.h */
  30. extern uint32 wl_msg_level;
  31. extern uint32 wl_msg_level2;
  32. #define WL_TIMESTAMP()
  33. #define WL_PRINT(args) do { WL_TIMESTAMP(); printf args; } while (0)
  34. #if defined(EVENT_LOG_COMPILE) && defined(WLMSG_SRSCAN)
  35. #define _WL_SRSCAN(fmt, ...) EVENT_LOG(EVENT_LOG_TAG_SRSCAN, fmt, ##__VA_ARGS__)
  36. #define WL_SRSCAN(args) _WL_SRSCAN args
  37. #else
  38. #define WL_SRSCAN(args)
  39. #endif
  40. /* To disable a message completely ... until you need it again */
  41. #define WL_NONE(args)
  42. #define WL_ERROR(args)
  43. #define WL_TRACE(args)
  44. #define WL_APSTA_UPDN(args)
  45. #define WL_APSTA_RX(args)
  46. #ifdef WLMSG_WSEC
  47. #define WL_WSEC(args) WL_PRINT(args)
  48. #define WL_WSEC_DUMP(args) WL_PRINT(args)
  49. #else
  50. #define WL_WSEC(args)
  51. #define WL_WSEC_DUMP(args)
  52. #endif
  53. #define WL_PCIE(args) do {if (wl_msg_level2 & WL_PCIE_VAL) WL_PRINT(args);} while (0)
  54. #define WL_PCIE_ON() (wl_msg_level2 & WL_PCIE_VAL)
  55. extern uint32 wl_msg_level;
  56. extern uint32 wl_msg_level2;
  57. #endif /* _wl_dbg_h_ */