diff options
author | Kuniyuki Iwashima <kuniyu@amazon.com> | 2024-01-23 09:08:53 -0800 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-01-26 20:34:24 -0800 |
commit | 97af84a6bba2ab2b9c704c08e67de3b5ea551bb2 (patch) | |
tree | 98c6d7b27da12a158a85b02f68f1204594b70dcc /include/net | |
parent | 31e03207119a535d0b0e3b3a7f91983aeb2cb14d (diff) | |
download | linux-97af84a6bba2ab2b9c704c08e67de3b5ea551bb2.tar.gz |
af_unix: Do not use atomic ops for unix_sk(sk)->inflight.
When touching unix_sk(sk)->inflight, we are always under
spin_lock(&unix_gc_lock).
Let's convert unix_sk(sk)->inflight to the normal unsigned long.
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://lore.kernel.org/r/20240123170856.41348-3-kuniyu@amazon.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/af_unix.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/af_unix.h b/include/net/af_unix.h index 49c4640027d8a..ac38b63db554f 100644 --- a/include/net/af_unix.h +++ b/include/net/af_unix.h @@ -61,7 +61,7 @@ struct unix_sock { struct mutex iolock, bindlock; struct sock *peer; struct list_head link; - atomic_long_t inflight; + unsigned long inflight; spinlock_t lock; unsigned long gc_flags; #define UNIX_GC_CANDIDATE 0 |