* [net-next-2.6 PATCH] Multiqueue support for bonding devices
@ 2010-02-23 15:16 "Oleg A. Arkhangelsky"
0 siblings, 0 replies; only message in thread
From: "Oleg A. Arkhangelsky" @ 2010-02-23 15:16 UTC (permalink / raw)
To: netdev
Make bonding driver multiqueue aware.
Signed-off-by: Oleg A. Arkhangelsky <sysoleg@yandex.ru>
---
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 1787e3c..f54f590 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -4928,8 +4928,9 @@ int bond_create(struct net *net, const char *name)
rtnl_lock();
- bond_dev = alloc_netdev(sizeof(struct bonding), name ? name : "",
- bond_setup);
+ bond_dev = alloc_netdev_mq(sizeof(struct bonding), name ? name : "",
+ bond_setup,
+ min_t(u32, BOND_MAX_TX_QUEUES, num_online_cpus()));
if (!bond_dev) {
pr_err("%s: eek! can't alloc netdev!\n", name);
res = -ENOMEM;
diff --git a/drivers/net/bonding/bonding.h b/drivers/net/bonding/bonding.h
index 257a7a4..eab3239 100644
--- a/drivers/net/bonding/bonding.h
+++ b/drivers/net/bonding/bonding.h
@@ -29,6 +29,7 @@
#define DRV_DESCRIPTION "Ethernet Channel Bonding Driver"
#define BOND_MAX_ARP_TARGETS 16
+#define BOND_MAX_TX_QUEUES 8
#define IS_UP(dev) \
((((dev)->flags & IFF_UP) == IFF_UP) && \
---
--
wbr, Oleg.
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-02-23 15:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-23 15:16 [net-next-2.6 PATCH] Multiqueue support for bonding devices "Oleg A. Arkhangelsky"
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox