From: Vincent Bernat <vincent@bernat.im>
To: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Cc: "David S. Miller" <davem@davemloft.net>,
Vijay Pandurangan <vijayp@vijayp.ca>,
Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org
Subject: Re: [PATCH] veth: delay peer link configuration after interfaces are tied
Date: Mon, 30 May 2016 17:26:51 +0200 [thread overview]
Message-ID: <87fusz36tg.fsf@zoro.exoscale.ch> (raw)
In-Reply-To: <574C59F1.80403@6wind.com> (Nicolas Dichtel's message of "Mon, 30 May 2016 17:19:13 +0200")
❦ 30 mai 2016 17:19 CEST, Nicolas Dichtel <nicolas.dichtel@6wind.com> :
>>>> priv = netdev_priv(peer);
>>>> rcu_assign_pointer(priv->peer, dev);
>>>> +
>>>> + err = rtnl_configure_link(peer, ifmp);
>>>> + if (err < 0)
>>>> + goto err_configure_peer;
>>
>>> You should fix the error path. 'unregister_netdevice(dev)' is missing.
>>
>> I am sending another patch to fix that. I am quite unsure if I do the
>> right thing here.
>>
> A less intrusive fix is to call 'rtmsg_ifinfo(RTM_NEWLINK, peer, ~0U,
> GFP_KERNEL);' a the end of veth_newlink().
I did that at first. Maybe this would make more sense to do
that. Otherwise, the first message contains an iflink value that we
cannot resolve with just the received netlink messages (since the
information is in the next netlink message). "ip monitor" seems to be
able to get the info, but I suppose it does an additional
lookup.
--
Make sure every module hides something.
- The Elements of Programming Style (Kernighan & Plauger)
next prev parent reply other threads:[~2016-05-30 15:26 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-29 11:17 [PATCH] veth: delay peer link configuration after interfaces are tied Vincent Bernat
2016-05-30 9:23 ` Nicolas Dichtel
2016-05-30 10:11 ` Vincent Bernat
2016-05-30 15:19 ` Nicolas Dichtel
2016-05-30 15:26 ` Vincent Bernat [this message]
2016-05-30 15:47 ` Nicolas Dichtel
2016-05-30 15:58 ` [net v3] veth: advertise peer link once both links are tied together Vincent Bernat
2016-05-30 16:01 ` Vincent Bernat
2016-05-30 16:27 ` Nicolas Dichtel
2016-05-31 6:29 ` Vincent Bernat
2016-05-31 9:17 ` Nicolas Dichtel
2016-06-08 20:30 ` Lance Richardson
2016-06-10 13:15 ` Nicolas Dichtel
2016-06-10 13:20 ` Lance Richardson
2016-05-31 6:30 ` [net v4] " Vincent Bernat
2016-05-31 6:54 ` Vincent Bernat
2016-05-30 10:12 ` [PATCH] veth: delay peer link configuration after interfaces are tied Vincent Bernat
2016-05-30 10:14 ` Vincent Bernat
2016-05-30 10:13 ` Vincent Bernat
2016-05-30 15:19 ` Nicolas Dichtel
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=87fusz36tg.fsf@zoro.exoscale.ch \
--to=vincent@bernat.im \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.com \
--cc=pabeni@redhat.com \
--cc=vijayp@vijayp.ca \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.