diff options
author | Eric Dumazet <edumazet@google.com> | 2024-02-28 14:54:34 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2024-03-01 09:42:32 +0100 |
commit | a8fbd4d90720b6c930661ed593d54aba77cec3c2 (patch) | |
tree | 99beb09ddf95a483c71a5795c6485d46cee031c9 /net/ipv6/ndisc.c | |
parent | ipv6: annotate data-races in rt6_probe() (diff) | |
download | linux-a8fbd4d90720b6c930661ed593d54aba77cec3c2.tar.xz linux-a8fbd4d90720b6c930661ed593d54aba77cec3c2.zip |
ipv6: annotate data-races around devconf->proxy_ndp
devconf->proxy_ndp can be read and written locklessly,
add appropriate annotations.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/ndisc.c')
-rw-r--r-- | net/ipv6/ndisc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/ipv6/ndisc.c b/net/ipv6/ndisc.c index f6430db24940..4114918f12c8 100644 --- a/net/ipv6/ndisc.c +++ b/net/ipv6/ndisc.c @@ -904,7 +904,8 @@ have_ifp: if (ipv6_chk_acast_addr(net, dev, &msg->target) || (READ_ONCE(idev->cnf.forwarding) && - (net->ipv6.devconf_all->proxy_ndp || idev->cnf.proxy_ndp) && + (READ_ONCE(net->ipv6.devconf_all->proxy_ndp) || + READ_ONCE(idev->cnf.proxy_ndp)) && (is_router = pndisc_is_router(&msg->target, dev)) >= 0)) { if (!(NEIGH_CB(skb)->flags & LOCALLY_ENQUEUED) && skb->pkt_type != PACKET_HOST && @@ -1101,7 +1102,7 @@ static enum skb_drop_reason ndisc_recv_na(struct sk_buff *skb) */ if (lladdr && !memcmp(lladdr, dev->dev_addr, dev->addr_len) && READ_ONCE(net->ipv6.devconf_all->forwarding) && - net->ipv6.devconf_all->proxy_ndp && + READ_ONCE(net->ipv6.devconf_all->proxy_ndp) && pneigh_lookup(&nd_tbl, net, &msg->target, dev, 0)) { /* XXX: idev->cnf.proxy_ndp */ goto out; |