diff --git a/include/asm-arm/atomic.h b/include/asm-arm/atomic.h index 75b802719723ad459d719b6f598254fe0dfe02e4..5f827509e923aa2e62b1d4b14fdfca691d7fd107 100644 --- a/include/asm-arm/atomic.h +++ b/include/asm-arm/atomic.h @@ -87,6 +87,7 @@ static inline int atomic_cmpxchg(atomic_t *ptr, int old, int new) do { __asm__ __volatile__("@ atomic_cmpxchg\n" "ldrex %1, [%2]\n" + "mov %0, #0\n" "teq %1, %3\n" "strexeq %0, %4, [%2]\n" : "=&r" (res), "=&r" (oldval)