aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRami Rosen <ramirose@gmail.com>2012-11-29 20:08:47 -0500
committerDavid S. Miller <davem@davemloft.net>2012-11-30 12:24:40 -0500
commitc07135633bee3f01a6454d15b6411f32cfbeb2fd (patch)
treeef75c8d8e2005c94be1117f6ab2c2a89320569ed
parentdad52fd964c54aa275ebb5c935ef8d8b0eded74d (diff)
rtnelink: remove unused parameter from rtnl_create_link().
This patch removes an unused parameter (src_net) from rtnl_create_link() method and from the method single invocation, in veth. This parameter was used in the past when calling ops->get_tx_queues(src_net, tb) in rtnl_create_link(). The get_tx_queues() member of rtnl_link_ops was replaced by two methods, get_num_tx_queues() and get_num_rx_queues(), which do not get any parameter. This was done in commit d40156aa5ecbd51fed932ed4813df82b56e5ff4d by Jiri Pirko ("rtnl: allow to specify different num for rx and tx queue count"). Signed-off-by: Rami Rosen <ramirose@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/veth.c2
-rw-r--r--include/net/rtnetlink.h2
-rw-r--r--net/core/rtnetlink.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/veth.c b/drivers/net/veth.c
index 24f6b27e169f..95814d9747ef 100644
--- a/drivers/net/veth.c
+++ b/drivers/net/veth.c
@@ -340,7 +340,7 @@ static int veth_newlink(struct net *src_net, struct net_device *dev,
340 if (IS_ERR(net)) 340 if (IS_ERR(net))
341 return PTR_ERR(net); 341 return PTR_ERR(net);
342 342
343 peer = rtnl_create_link(src_net, net, ifname, &veth_link_ops, tbp); 343 peer = rtnl_create_link(net, ifname, &veth_link_ops, tbp);
344 if (IS_ERR(peer)) { 344 if (IS_ERR(peer)) {
345 put_net(net); 345 put_net(net);
346 return PTR_ERR(peer); 346 return PTR_ERR(peer);
diff --git a/include/net/rtnetlink.h b/include/net/rtnetlink.h
index 6b00c4fc4291..5a15fabd6a75 100644
--- a/include/net/rtnetlink.h
+++ b/include/net/rtnetlink.h
@@ -125,7 +125,7 @@ extern void rtnl_af_unregister(struct rtnl_af_ops *ops);
125 125
126 126
127extern struct net *rtnl_link_get_net(struct net *src_net, struct nlattr *tb[]); 127extern struct net *rtnl_link_get_net(struct net *src_net, struct nlattr *tb[]);
128extern struct net_device *rtnl_create_link(struct net *src_net, struct net *net, 128extern struct net_device *rtnl_create_link(struct net *net,
129 char *ifname, const struct rtnl_link_ops *ops, struct nlattr *tb[]); 129 char *ifname, const struct rtnl_link_ops *ops, struct nlattr *tb[]);
130extern int rtnl_configure_link(struct net_device *dev, 130extern int rtnl_configure_link(struct net_device *dev,
131 const struct ifinfomsg *ifm); 131 const struct ifinfomsg *ifm);
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 575a6ee89944..1868625af25e 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -1642,7 +1642,7 @@ int rtnl_configure_link(struct net_device *dev, const struct ifinfomsg *ifm)
1642} 1642}
1643EXPORT_SYMBOL(rtnl_configure_link); 1643EXPORT_SYMBOL(rtnl_configure_link);
1644 1644
1645struct net_device *rtnl_create_link(struct net *src_net, struct net *net, 1645struct net_device *rtnl_create_link(struct net *net,
1646 char *ifname, const struct rtnl_link_ops *ops, struct nlattr *tb[]) 1646 char *ifname, const struct rtnl_link_ops *ops, struct nlattr *tb[])
1647{ 1647{
1648 int err; 1648 int err;
@@ -1840,7 +1840,7 @@ replay:
1840 if (IS_ERR(dest_net)) 1840 if (IS_ERR(dest_net))
1841 return PTR_ERR(dest_net); 1841 return PTR_ERR(dest_net);
1842 1842
1843 dev = rtnl_create_link(net, dest_net, ifname, ops, tb); 1843 dev = rtnl_create_link(dest_net, ifname, ops, tb);
1844 if (IS_ERR(dev)) { 1844 if (IS_ERR(dev)) {
1845 err = PTR_ERR(dev); 1845 err = PTR_ERR(dev);
1846 goto out; 1846 goto out;