diff options
author | Eric Dumazet <edumazet@google.com> | 2023-08-16 08:15:46 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2023-08-16 11:09:18 +0100 |
commit | 10f42426e5bcea728d7fae96609b29b4fb1f7518 (patch) | |
tree | 96616c34b54ec1557e0b65ed307efd6f060141a4 /net/ipv4/sysctl_net_ipv4.c | |
parent | 08e39c0dfa29f233f5a621f7d274b793a080c769 (diff) | |
download | linux-10f42426e5bcea728d7fae96609b29b4fb1f7518.tar.gz linux-10f42426e5bcea728d7fae96609b29b4fb1f7518.tar.bz2 linux-10f42426e5bcea728d7fae96609b29b4fb1f7518.zip |
inet: implement lockless IP_TTL
ip_select_ttl() is racy, because it reads inet->uc_ttl
without proper locking.
Add READ_ONCE()/WRITE_ONCE() annotations while
allowing IP_TTL socket option to be set/read without
holding the socket lock.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Soheil Hassas Yeganeh <soheil@google.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/sysctl_net_ipv4.c')
0 files changed, 0 insertions, 0 deletions