]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-arm/atomic.h
Merge branch 'for-linus' of git://neil.brown.name/md
[linux-2.6-omap-h63xx.git] / include / asm-arm / atomic.h
index ea88aa6bfc78e91c9d0442ab2b504e3ddabe1c56..3b59f94b5a3d3f345bf5bfeff53440063ae3f426 100644 (file)
@@ -12,6 +12,7 @@
 #define __ASM_ARM_ATOMIC_H
 
 #include <linux/compiler.h>
+#include <asm/system.h>
 
 typedef struct { volatile int counter; } atomic_t;
 
@@ -103,9 +104,9 @@ static inline void atomic_clear_mask(unsigned long mask, unsigned long *addr)
        unsigned long tmp, tmp2;
 
        __asm__ __volatile__("@ atomic_clear_mask\n"
-"1:    ldrex   %0, %2\n"
+"1:    ldrex   %0, [%2]\n"
 "      bic     %0, %0, %3\n"
-"      strex   %1, %0, %2\n"
+"      strex   %1, %0, [%2]\n"
 "      teq     %1, #0\n"
 "      bne     1b"
        : "=&r" (tmp), "=&r" (tmp2)