1 1.1.2.2 skrll #ifdef __FreeBSD__ 2 1.1.2.2 skrll typedef struct mtx ieee80211_node_lock_t; 3 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_INIT(_ic, _name) \ 4 1.1.2.2 skrll mtx_init(&(_ic)->ic_nodelock, _name, "802.11 node table", MTX_DEF) 5 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_DESTROY(_ic) mtx_destroy(&(_ic)->ic_nodelock) 6 1.1.2.2 skrll #define IEEE80211_NODE_LOCK(_ic) mtx_lock(&(_ic)->ic_nodelock) 7 1.1.2.2 skrll #define IEEE80211_NODE_UNLOCK(_ic) mtx_unlock(&(_ic)->ic_nodelock) 8 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_ASSERT(_ic) \ 9 1.1.2.2 skrll mtx_assert(&(_ic)->ic_nodelock, MA_OWNED) 10 1.1.2.2 skrll #else 11 1.1.2.2 skrll typedef int ieee80211_node_lock_t; 12 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_INIT(_ic, _name) 13 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_DESTROY(_ic) 14 1.1.2.2 skrll #define IEEE80211_NODE_LOCK(_ic) (_ic)->ic_nodelock = splnet() 15 1.1.2.2 skrll #define IEEE80211_NODE_UNLOCK(_ic) splx((_ic)->ic_nodelock) 16 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_ASSERT(_ic) 17 1.1.2.2 skrll #endif 18 1.1.2.2 skrll #define IEEE80211_NODE_LOCK_BH IEEE80211_NODE_LOCK 19 1.1.2.2 skrll #define IEEE80211_NODE_UNLOCK_BH IEEE80211_NODE_UNLOCK 20