Lines Matching refs:lock

403 	spinlock_t lock;  member
413 .lock = __SPIN_LOCK_UNLOCKED(lockname) \
419 spin_lock_init(&(x)->lock); \
445 spin_lock(&sl->lock); in write_seqlock()
452 spin_unlock(&sl->lock); in write_sequnlock()
457 spin_lock_bh(&sl->lock); in write_seqlock_bh()
464 spin_unlock_bh(&sl->lock); in write_sequnlock_bh()
469 spin_lock_irq(&sl->lock); in write_seqlock_irq()
476 spin_unlock_irq(&sl->lock); in write_sequnlock_irq()
483 spin_lock_irqsave(&sl->lock, flags); in __write_seqlock_irqsave()
488 #define write_seqlock_irqsave(lock, flags) \ argument
489 do { flags = __write_seqlock_irqsave(lock); } while (0)
495 spin_unlock_irqrestore(&sl->lock, flags); in write_sequnlock_irqrestore()
505 spin_lock(&sl->lock); in read_seqlock_excl()
510 spin_unlock(&sl->lock); in read_sequnlock_excl()
523 static inline void read_seqbegin_or_lock(seqlock_t *lock, int *seq) in read_seqbegin_or_lock() argument
526 *seq = read_seqbegin(lock); in read_seqbegin_or_lock()
528 read_seqlock_excl(lock); in read_seqbegin_or_lock()
531 static inline int need_seqretry(seqlock_t *lock, int seq) in need_seqretry() argument
533 return !(seq & 1) && read_seqretry(lock, seq); in need_seqretry()
536 static inline void done_seqretry(seqlock_t *lock, int seq) in done_seqretry() argument
539 read_sequnlock_excl(lock); in done_seqretry()
544 spin_lock_bh(&sl->lock); in read_seqlock_excl_bh()
549 spin_unlock_bh(&sl->lock); in read_sequnlock_excl_bh()
554 spin_lock_irq(&sl->lock); in read_seqlock_excl_irq()
559 spin_unlock_irq(&sl->lock); in read_sequnlock_excl_irq()
566 spin_lock_irqsave(&sl->lock, flags); in __read_seqlock_excl_irqsave()
570 #define read_seqlock_excl_irqsave(lock, flags) \ argument
571 do { flags = __read_seqlock_excl_irqsave(lock); } while (0)
576 spin_unlock_irqrestore(&sl->lock, flags); in read_sequnlock_excl_irqrestore()
580 read_seqbegin_or_lock_irqsave(seqlock_t *lock, int *seq) in read_seqbegin_or_lock_irqsave() argument
585 *seq = read_seqbegin(lock); in read_seqbegin_or_lock_irqsave()
587 read_seqlock_excl_irqsave(lock, flags); in read_seqbegin_or_lock_irqsave()
593 done_seqretry_irqrestore(seqlock_t *lock, int seq, unsigned long flags) in done_seqretry_irqrestore() argument
596 read_sequnlock_excl_irqrestore(lock, flags); in done_seqretry_irqrestore()