From: Sabrina Dubroca <sd@queasysnail.net>
To: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Cc: netdev@vger.kernel.org, Dan Winship <danw@redhat.com>
Subject: Re: [PATCH net] rtnetlink: always put ILFA_LINK for links with a link-netnsid
Date: Mon, 13 May 2019 15:42:06 +0200 [thread overview]
Message-ID: <20190513134206.GA13340@bistromath.localdomain> (raw)
In-Reply-To: <a9ba6631-4403-67e0-152a-b2d85aa70d72@6wind.com>
2019-05-13, 15:17:33 +0200, Nicolas Dichtel wrote:
> Le 13/05/2019 à 15:01, Sabrina Dubroca a écrit :
> > Currently, nla_put_iflink() doesn't put the IFLA_LINK attribute when
> > iflink == ifindex.
> >
> > In some cases, a device can be created in a different netns with the
> > same ifindex as its parent. That device will not dump its IFLA_LINK
> > attribute, which can confuse some userspace software that expects it.
> > For example, if the last ifindex created in init_net and foo are both
> > 8, these commands will trigger the issue:
> >
> > ip link add parent type dummy # ifindex 9
> > ip link add link parent netns foo type macvlan # ifindex 9 in ns foo
> >
> > So, in case a device puts the IFLA_LINK_NETNSID attribute in a dump,
> > always put the IFLA_LINK attribute as well.
> >
> > Thanks to Dan Winship for analyzing the original OpenShift bug down to
> > the missing netlink attribute.
> Good catch.
>
> >
> > Analyzed-by: Dan Winship <danw@redhat.com>
> > Fixes: a54acb3a6f85 ("dev: introduce dev_get_iflink()")
> I don't agree with the Fixes tag. The test 'iflink != ifindex' is here at least
> since the beginning of the git history.
Hmpf, right, now that I re-blamed, I see. I don't know why I stopped
on your patch, sorry.
> > Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
> Acked-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Thanks!
I'll repost with a correct Fixes tag and your Ack.
--
Sabrina
prev parent reply other threads:[~2019-05-13 13:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-13 13:01 [PATCH net] rtnetlink: always put ILFA_LINK for links with a link-netnsid Sabrina Dubroca
2019-05-13 13:17 ` Nicolas Dichtel
2019-05-13 13:42 ` Sabrina Dubroca [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190513134206.GA13340@bistromath.localdomain \
--to=sd@queasysnail.net \
--cc=danw@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox