* [patch net-next] rtnetlink: remove check for fill_slave_info in rtnl_have_link_slave_info
@ 2014-01-23 18:19 Jiri Pirko
2014-01-24 0:22 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Jiri Pirko @ 2014-01-23 18:19 UTC (permalink / raw)
To: netdev; +Cc: davem, sfeldma, nicolas.dichtel, john.r.fastabend, vyasevich
This check is not needed because the same check is done before
fill_slave_info is used in rtnl_link_slave_info_fill.
Also, by removing this check, kernel will fillup IFLA_INFO_SLAVE_KIND
even for slaves of masters which does not implement fill_slave_info.
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
---
net/core/rtnetlink.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index db6a239..393b1bc 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -482,8 +482,7 @@ static bool rtnl_have_link_slave_info(const struct net_device *dev)
struct net_device *master_dev;
master_dev = netdev_master_upper_dev_get((struct net_device *) dev);
- if (master_dev && master_dev->rtnl_link_ops &&
- master_dev->rtnl_link_ops->fill_slave_info)
+ if (master_dev && master_dev->rtnl_link_ops)
return true;
return false;
}
--
1.8.3.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-01-24 0:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-23 18:19 [patch net-next] rtnetlink: remove check for fill_slave_info in rtnl_have_link_slave_info Jiri Pirko
2014-01-24 0:22 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox