History

m68k: cmpxchg: Fix return value for default case in __arch_xchg()

The return value of __invalid_xchg_size() is assigned to tmp instead of the return variable x. Assign it to x instead.

Thorsten Blum committed 2 years ago

Commit 21b9e721 parent 75d38911 file · +1 −1Browse files

Unified · Split

arch/m68k/include/asm/cmpxchg.h+1−1
@@ -32,7 +32,7 @@ static inline unsigned long __arch_xchg(unsigned long x, volatile void * ptr, in · 31 unmodified lines
3232 x = tmp;
3333 break;
3434 default:
35− tmp = __invalid_xchg_size(x, ptr, size);
35+ x = __invalid_xchg_size(x, ptr, size);
3636 break;
3737 }
3838