summaryrefslogtreecommitdiff
path: root/arch/arm/include/asm/spinlock.h
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2013-02-20 18:35:58 +0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2013-02-20 18:35:58 +0400
commit1b1c7409b75a8b62906b78b84c8469002072b738 (patch)
tree91ceea4d8fae61b29e9a716c5e6ad56c3b5f588b /arch/arm/include/asm/spinlock.h
parent573f8c8d13377ec03c2d23269f8eea50c11a7432 (diff)
parentb28748fb5d21d5d64c9ce31579ffbbd41f317042 (diff)
downloadlinux-1b1c7409b75a8b62906b78b84c8469002072b738.tar.xz
Merge branch 'misc' into for-linus
Conflicts: arch/arm/include/asm/memory.h
Diffstat (limited to 'arch/arm/include/asm/spinlock.h')
-rw-r--r--arch/arm/include/asm/spinlock.h16
1 files changed, 1 insertions, 15 deletions
diff --git a/arch/arm/include/asm/spinlock.h b/arch/arm/include/asm/spinlock.h
index b4ca707d0a69..6220e9fdf4c7 100644
--- a/arch/arm/include/asm/spinlock.h
+++ b/arch/arm/include/asm/spinlock.h
@@ -119,22 +119,8 @@ static inline int arch_spin_trylock(arch_spinlock_t *lock)
static inline void arch_spin_unlock(arch_spinlock_t *lock)
{
- unsigned long tmp;
- u32 slock;
-
smp_mb();
-
- __asm__ __volatile__(
-" mov %1, #1\n"
-"1: ldrex %0, [%2]\n"
-" uadd16 %0, %0, %1\n"
-" strex %1, %0, [%2]\n"
-" teq %1, #0\n"
-" bne 1b"
- : "=&r" (slock), "=&r" (tmp)
- : "r" (&lock->slock)
- : "cc");
-
+ lock->tickets.owner++;
dsb_sev();
}