ipv4: use RCU protection in rt_is_expired()
authorEric Dumazet <edumazet@google.com>
Wed, 5 Feb 2025 15:51:13 +0000 (15:51 +0000)
committerJakub Kicinski <kuba@kernel.org>
Fri, 7 Feb 2025 00:14:14 +0000 (16:14 -0800)
commitdd205fcc33d92d54eee4d7f21bb073af9bd5ce2b
treec14d5cb58d9b25c45ac73338cc75a9f4389713c9
parent71b8471c93fa0bcab911fcb65da1eb6c4f5f735f
ipv4: use RCU protection in rt_is_expired()

rt_is_expired() must use RCU protection to make
sure the net structure it reads does not disappear.

Fixes: e84f84f27647 ("netns: place rt_genid into struct net")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Link: https://patch.msgid.link/20250205155120.1676781-6-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/ipv4/route.c