[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iJNYT004pYCApzjqezcJ-UbzvSzNbD8MGMb7OLt_Rjt3A@mail.gmail.com>
Date: Tue, 5 Nov 2024 11:23:50 +0100
From: Eric Dumazet <edumazet@...gle.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>
Cc: "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
Andrew Lunn <andrew+netdev@...n.ch>, Marc Kleine-Budde <mkl@...gutronix.de>,
Vincent Mailhol <mailhol.vincent@...adoo.fr>, Daniel Borkmann <daniel@...earbox.net>,
Nikolay Aleksandrov <razor@...ckwall.org>, Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v1 net-next 3/8] rtnetlink: Add peer_type in struct rtnl_link_ops.
On Tue, Nov 5, 2024 at 3:06 AM Kuniyuki Iwashima <kuniyu@...zon.com> wrote:
>
> For veth, vxcan, and netkit, we need to prefetch the peer device's
> netns in rtnl_newlink() for per-netns RTNL.
>
> All of the three get the netns in the same way peer netlink attr tb:
>
> 1. Call rtnl_nla_parse_ifinfomsg()
> 2. Call ops->validate() (vxcan doesn't have)
> 3. Call rtnl_link_get_net_tb()
>
> Let's add a new field peer_type to struct rtnl_link_ops and fetch
> netns in peer attrbutes to add it to rtnl_nets in rtnl_newlink().
>
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...zon.com>
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists