[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iJSoijSbzagUEptz=qp9p+WDgZR-Uf8099j7ahaqce+nA@mail.gmail.com>
Date: Fri, 24 Oct 2025 05:33:50 -0700
From: Eric Dumazet <edumazet@...gle.com>
To: Kuniyuki Iwashima <kuniyu@...gle.com>
Cc: "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, David Ahern <dsahern@...nel.org>, Simon Horman <horms@...nel.org>,
Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v1 net-next 2/5] neighbour: Annotate access to neigh_parms fields.
On Tue, Oct 21, 2025 at 10:40 PM Kuniyuki Iwashima <kuniyu@...gle.com> wrote:
>
> NEIGH_VAR() is read locklessly in the fast path, and IPv6 ndisc uses
> NEIGH_VAR_SET() locklessly.
>
> The next patch will convert neightbl_dump_info() to RCU.
>
> Let's annotate accesses to neigh_param with READ_ONCE() and WRITE_ONCE().
>
> Note that ndisc_ifinfo_sysctl_change() uses &NEIGH_VAR() and we cannot
> use '&' with READ_ONCE(), so NEIGH_VAR_PTR() is introduced.
>
> Note also that NEIGH_VAR_INIT() does not need WRITE_ONCE() as it is before
> parms is published. Also, the only user hippi_neigh_setup_dev() is no
> longer called since commit e3804cbebb67 ("net: remove COMPAT_NET_DEV_OPS"),
> which looks wrong, but probably no one uses HIPPI and RoadRunner.
>
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...gle.com>
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists