lib: Fix typo in atomic exchange functions

There is a typo in atomic operations code which prevents the
usage of riscv atomic instructions even if it is supported.

Fix the typo.

Signed-off-by: Atish Patra <atish.patra@wdc.com>
Reviewed-by: Anup Patel <anup.patel@wdc.com>
This commit is contained in:
Atish Patra
2020-02-21 15:47:53 -08:00
committed by Anup Patel
parent 3e7d666d7c
commit c3b3b8f43b

View File

@@ -79,7 +79,7 @@ long atomic_sub_return(atomic_t *atom, long value)
#define axchg(ptr, x) \
({ \
__typeof__(*(ptr)) _x_ = (x); \
(__typeof__(*(ptr))) __xchg((ptr), _x_, sizeof(*(ptr))); \
(__typeof__(*(ptr))) __axchg((ptr), _x_, sizeof(*(ptr))); \
})