aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/core/rtnetlink.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 045db8ad87c8..db5a8ad8a79b 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -1624,17 +1624,17 @@ struct net_device *rtnl_create_link(struct net *src_net, struct net *net,
1624{ 1624{
1625 int err; 1625 int err;
1626 struct net_device *dev; 1626 struct net_device *dev;
1627 unsigned int num_queues = 1; 1627 unsigned int num_tx_queues = 1;
1628 unsigned int num_rx_queues = 1;
1628 1629
1629 if (ops->get_tx_queues) { 1630 if (ops->get_num_tx_queues)
1630 err = ops->get_tx_queues(src_net, tb); 1631 num_tx_queues = ops->get_num_tx_queues();
1631 if (err < 0) 1632 if (ops->get_num_rx_queues)
1632 goto err; 1633 num_rx_queues = ops->get_num_rx_queues();
1633 num_queues = err;
1634 }
1635 1634
1636 err = -ENOMEM; 1635 err = -ENOMEM;
1637 dev = alloc_netdev_mq(ops->priv_size, ifname, ops->setup, num_queues); 1636 dev = alloc_netdev_mqs(ops->priv_size, ifname, ops->setup,
1637 num_tx_queues, num_rx_queues);
1638 if (!dev) 1638 if (!dev)
1639 goto err; 1639 goto err;
1640 1640