diff options
author | Mark Rutland <mark.rutland@arm.com> | 2021-05-25 17:02:01 +0300 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2021-05-26 14:20:49 +0300 |
commit | 201e2c1bbe659720913ed5272a2c44e6ab646c8a (patch) | |
tree | 7f884d88ba2bea8200b642c42ec72f4ce569f429 /net/sunrpc/xprtmultipath.c | |
parent | 9be85de97786a75f62080de1c0c13656f65cba84 (diff) | |
download | linux-201e2c1bbe659720913ed5272a2c44e6ab646c8a.tar.xz |
locking/atomic: net: use linux/atomic.h for xchg & cmpxchg
As xchg*() and cmpxchg*() may be instrumented by atomic-instrumented.h,
it's necessary to include <linux/atomic.h> to use these, rather than
<asm/cmpxchg.h>, which is effectively an arch-internal header.
In a couple of places we include <asm/cmpxchg.h>, but get away with this
as <linux/atomic.h> gets pulled in inidrectly by another include. Before
we convert more architectures to use atomic-instrumented.h, let's fix
these up to use <linux/atomic.h> so that we don't make things more
fragile.
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Boqun Feng <boqun.feng@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20210525140232.53872-3-mark.rutland@arm.com
Diffstat (limited to 'net/sunrpc/xprtmultipath.c')
-rw-r--r-- | net/sunrpc/xprtmultipath.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/sunrpc/xprtmultipath.c b/net/sunrpc/xprtmultipath.c index 78c075a68c04..1b4073131c6f 100644 --- a/net/sunrpc/xprtmultipath.c +++ b/net/sunrpc/xprtmultipath.c @@ -7,13 +7,13 @@ * Trond Myklebust <trond.myklebust@primarydata.com> * */ +#include <linux/atomic.h> #include <linux/types.h> #include <linux/kref.h> #include <linux/list.h> #include <linux/rcupdate.h> #include <linux/rculist.h> #include <linux/slab.h> -#include <asm/cmpxchg.h> #include <linux/spinlock.h> #include <linux/sunrpc/xprt.h> #include <linux/sunrpc/addr.h> |