[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250206153951.41fbcb84@kernel.org>
Date: Thu, 6 Feb 2025 15:39:51 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Nicolas Dichtel <nicolas.dichtel@...nd.com>
Cc: "David S . Miller" <davem@...emloft.net>, Paolo Abeni
<pabeni@...hat.com>, Eric Dumazet <edumazet@...gle.com>, Alexander Lobakin
<aleksander.lobakin@...el.com>, netdev@...r.kernel.org,
stable@...r.kernel.org
Subject: Re: [PATCH net 1/2] net: advertise 'netns local' property via
netlink
On Thu, 6 Feb 2025 17:50:26 +0100 Nicolas Dichtel wrote:
> Since the below commit, there is no way to see if the netns_local property
> is set on a device. Let's add a netlink attribute to advertise it.
I think the motivation for the change may be worth elaborating on.
It's a bit unclear to me what user space would care about this
information, a bit of a "story" on how you hit the issue could
be useful perhaps? The uAPI is new but the stable tag indicates
regression..
> @@ -2041,6 +2042,7 @@ static int rtnl_fill_ifinfo(struct sk_buff *skb,
> netif_running(dev) ? READ_ONCE(dev->operstate) :
> IF_OPER_DOWN) ||
> nla_put_u8(skb, IFLA_LINKMODE, READ_ONCE(dev->link_mode)) ||
> + nla_put_u8(skb, IFLA_NETNS_LOCAL, dev->netns_local) ||
Maybe nla_put_flag() ? Or do you really care about false being there?
The 3 bytes wasted on padding always makes me question when people pick
NLA_u8.
> nla_put_u32(skb, IFLA_MTU, READ_ONCE(dev->mtu)) ||
> nla_put_u32(skb, IFLA_MIN_MTU, READ_ONCE(dev->min_mtu)) ||
> nla_put_u32(skb, IFLA_MAX_MTU, READ_ONCE(dev->max_mtu)) ||
Powered by blists - more mailing lists