Commit c35f0b59 authored by Nicolas Dichtel's avatar Nicolas Dichtel Committed by Sasha Levin

rtnl: restore notifications for deleted interfaces

The commit 984ff7a3 is an upstream backport. In fact, it depends on
commit 395eea6c ("rtnetlink: delay RTM_DELLINK notification until after ndo_uninit()")
which has not been backported in 3.18.y.

Before commit 395eea6c, rollback_registered_many() uses rtmsg_ifinfo().
The call to this function is done with dev->reg_state set to
NETREG_UNREGISTERING, thus testing this reg_state in rtmsg_ifinfo() is
wrong.

This patch partially reverts commit 984ff7a3.

Fixes: 984ff7a3 ("rtnl/bond: don't send rtnl msg for unregistered iface")
Reported-by: default avatarKristian Evensen <kristian.evensen@gmail.com>
Signed-off-by: default avatarNicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: default avatarSasha Levin <sasha.levin@oracle.com>
parent 14123aec
......@@ -2229,9 +2229,6 @@ void rtmsg_ifinfo(int type, struct net_device *dev, unsigned int change,
int err = -ENOBUFS;
size_t if_info_size;
if (dev->reg_state != NETREG_REGISTERED)
return;
skb = nlmsg_new((if_info_size = if_nlmsg_size(dev, 0)), flags);
if (skb == NULL)
goto errout;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment