Lines Matching full:sk_lock
249 * @sk_lock: synchronizer
473 socket_lock_t sk_lock;
1687 * Mark both the sk_lock and the sk_lock.slock as a
1693 sk->sk_lock.owned = 0; \
1694 init_waitqueue_head(&sk->sk_lock.wq); \
1695 spin_lock_init(&(sk)->sk_lock.slock); \
1696 debug_check_no_locks_freed((void *)&(sk)->sk_lock, \
1697 sizeof((sk)->sk_lock)); \
1698 lockdep_set_class_and_name(&(sk)->sk_lock.slock, \
1700 lockdep_init_map(&(sk)->sk_lock.dep_map, (name), (key), 0); \
1705 return lockdep_is_held(&sk->sk_lock) ||
1706 lockdep_is_held(&sk->sk_lock.slock);
1720 #define bh_lock_sock(__sk) spin_lock(&((__sk)->sk_lock.slock))
1722 spin_lock_nested(&((__sk)->sk_lock.slock), \
1724 #define bh_unlock_sock(__sk) spin_unlock(&((__sk)->sk_lock.slock))
1726 bool __lock_sock_fast(struct sock *sk) __acquires(&sk->sk_lock.slock);
1735 * sk_lock.slock locked, owned = 0, BH disabled
1739 * sk_lock.slock unlocked, owned = 1, BH enabled
1743 /* The sk_lock has mutex_lock() semantics here. */
1744 mutex_acquire(&sk->sk_lock.dep_map, 0, 0, _RET_IP_);
1752 mutex_acquire(&sk->sk_lock.dep_map, SINGLE_DEPTH_NESTING, 0, _RET_IP_);
1766 __releases(&sk->sk_lock.slock)
1770 __release(&sk->sk_lock.slock);
1772 mutex_release(&sk->sk_lock.dep_map, _RET_IP_);
1773 spin_unlock_bh(&sk->sk_lock.slock);
1813 return sk->sk_lock.owned;
1818 return sk->sk_lock.owned;
1824 sk->sk_lock.owned = 0;
1826 /* The sk_lock has mutex_unlock() semantics: */
1827 mutex_release(&sk->sk_lock.dep_map, _RET_IP_);
1836 !spin_is_locked(&sk->sk_lock.slock);