diff options
| author | Eric Dumazet <edumazet@google.com> | 2026-07-01 12:50:16 +0000 |
|---|---|---|
| committer | Paolo Abeni <pabeni@redhat.com> | 2026-07-06 11:45:44 +0200 |
| commit | 586c4dcf28eb68756d44a30cfcc9535380f07cc6 (patch) | |
| tree | bc4da08d98a364a36ba052ef63e88ae1045df359 /include | |
| parent | d7261cdb9550733b9003123eabb986d80fa9155d (diff) | |
| download | linux-next-586c4dcf28eb68756d44a30cfcc9535380f07cc6.tar.gz linux-next-586c4dcf28eb68756d44a30cfcc9535380f07cc6.zip | |
amt: no longer rely on RTNL in amt_fill_info()
Update amt_fill_info() to run under RCU read lock instead of RTNL.
The AMT device configuration fields (mode, relay_port, gw_port, local_ip,
discovery_ip, max_tunnels) and stream_dev pointer are initialized during
device creation (amt_newlink) and are immutable. Accessing them locklessly
is safe. The stream_dev net_device structure is protected from being freed
by RCU.
The only field that can change concurrently is amt->remote_ip, which is
updated in the packet receive path (amt_advertisement_handler) and
workqueue (amt_req_work). Add READ_ONCE()/WRITE_ONCE() annotations
around amt->remote_ip to prevent data races.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com>
Link: https://patch.msgid.link/20260701125016.3650708-1-edumazet@google.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
