Lines Matching defs:lock
44 static inline void hyp_spin_lock(hyp_spinlock_t *lock)
63 /* Did we get the lock? */
75 /* We got the lock. Critical section starts here. */
77 : "=&r" (lockval), "=&r" (newval), "=&r" (tmp), "+Q" (*lock)
78 : "Q" (lock->owner)
82 static inline void hyp_spin_unlock(hyp_spinlock_t *lock)
96 : "=Q" (lock->owner), "=&r" (tmp)
101 static inline bool hyp_spin_is_locked(hyp_spinlock_t *lock)
103 hyp_spinlock_t lockval = READ_ONCE(*lock);
109 static inline void hyp_assert_lock_held(hyp_spinlock_t *lock)
116 * wait until it is set before checking the lock state.
119 BUG_ON(!hyp_spin_is_locked(lock));
122 static inline void hyp_assert_lock_held(hyp_spinlock_t *lock) { }