7 #ifndef __BFIN_SPINLOCK_H
8 #define __BFIN_SPINLOCK_H
29 return __raw_spin_is_locked_asm(&lock->
lock);
34 __raw_spin_lock_asm(&lock->
lock);
37 #define arch_spin_lock_flags(lock, flags) arch_spin_lock(lock)
41 return __raw_spin_trylock_asm(&lock->
lock);
46 __raw_spin_unlock_asm(&lock->
lock);
57 return __raw_uncached_fetch_asm(&rw->
lock) > 0;
67 __raw_read_lock_asm(&rw->
lock);
70 #define arch_read_lock_flags(lock, flags) arch_read_lock(lock)
74 return __raw_read_trylock_asm(&rw->
lock);
79 __raw_read_unlock_asm(&rw->
lock);
84 __raw_write_lock_asm(&rw->
lock);
87 #define arch_write_lock_flags(lock, flags) arch_write_lock(lock)
91 return __raw_write_trylock_asm(&rw->
lock);
96 __raw_write_unlock_asm(&rw->
lock);
99 #define arch_spin_relax(lock) cpu_relax()
100 #define arch_read_relax(lock) cpu_relax()
101 #define arch_write_relax(lock) cpu_relax()