Lines Matching refs:lock
23 static inline void spinlock_init(spinlock_t *lock) in spinlock_init() argument
25 (void)memset(lock, 0U, sizeof(spinlock_t)); in spinlock_init()
28 static inline void spinlock_obtain(spinlock_t *lock) in spinlock_obtain() argument
46 [head] "m"(lock->head), in spinlock_obtain()
47 [tail] "m"(lock->tail) in spinlock_obtain()
51 static inline void spinlock_release(spinlock_t *lock) in spinlock_release() argument
56 : [tail] "m" (lock->tail) in spinlock_release()
68 .macro spinlock_obtain lock
70 lea \lock, % rbx
71 lock xaddl % eax, SYNC_SPINLOCK_HEAD_OFFSET(%rbx)
81 #define spinlock_obtain(x) spinlock_obtain lock = (x)
83 .macro spinlock_release lock
84 lea \lock, % rbx
85 lock incl SYNC_SPINLOCK_TAIL_OFFSET(%rbx)
88 #define spinlock_release(x) spinlock_release lock = (x)
92 #define spinlock_irqsave_obtain(lock, p_rflags) \ argument
95 spinlock_obtain(lock); \
98 #define spinlock_irqrestore_release(lock, rflags) \ argument
100 spinlock_release(lock); \