1 /* Slow paths of read/write spinlocks. */
3 #include <linux/linkage.h>
4 #include <asm/rwlock.h>
5 #include <asm/alternative-asm.h>
6 #include <asm/dwarf2.h>
8 /* rdi: pointer to rwlock_t */
9 ENTRY(__write_lock_failed)
12 addl $RW_LOCK_BIAS,(%rdi)
15 cmpl $RW_LOCK_BIAS,(%rdi)
18 subl $RW_LOCK_BIAS,(%rdi)
19 jnz __write_lock_failed
22 END(__write_lock_failed)
24 /* rdi: pointer to rwlock_t */
25 ENTRY(__read_lock_failed)
38 END(__read_lock_failed)