aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/tcp_ipv6.c
diff options
context:
space:
mode:
authorEric Dumazet <[email protected]>2023-09-12 16:02:08 +0000
committerDavid S. Miller <[email protected]>2023-09-15 09:33:48 +0000
commit3fa29971c69519629370b119b0b618ee88ade6b9 (patch)
tree3008d12c2cb04af2d4e8038799d28dcfce797b7b /net/ipv6/tcp_ipv6.c
parentipv6: lockless IPV6_DONTFRAG implementation (diff)
downloadkernel-3fa29971c69519629370b119b0b618ee88ade6b9.tar.gz
kernel-3fa29971c69519629370b119b0b618ee88ade6b9.zip
ipv6: lockless IPV6_RECVERR implemetation
np->recverr is moved to inet->inet_flags to fix data-races. Signed-off-by: Eric Dumazet <[email protected]> Reviewed-by: David Ahern <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r--net/ipv6/tcp_ipv6.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index 54db5fab318b..b5954b136b57 100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -508,7 +508,7 @@ static int tcp_v6_err(struct sk_buff *skb, struct inet6_skb_parm *opt,
tcp_ld_RTO_revert(sk, seq);
}
- if (!sock_owned_by_user(sk) && np->recverr) {
+ if (!sock_owned_by_user(sk) && inet6_test_bit(RECVERR6, sk)) {
WRITE_ONCE(sk->sk_err, err);
sk_error_report(sk);
} else {