From: Eric Dumazet <eric.dumazet@gmail.com>
To: "Krzysztof Olędzki" <ole@ans.pl>
Cc: Michael Chan <mchan@broadcom.com>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: bnx2/BCM5709: why 5 interrupts on a 4 core system (2.6.33.3)
Date: Sun, 16 May 2010 22:47:06 +0200 [thread overview]
Message-ID: <1274042826.2299.26.camel@edumazet-laptop> (raw)
In-Reply-To: <4BF056F0.8010008@ans.pl>
Le dimanche 16 mai 2010 à 22:34 +0200, Krzysztof Olędzki a écrit :
> On 2010-05-16 22:15, Eric Dumazet wrote:
> > All tx packets through bonding will use txqueue 0, since bnx2 doesnt
> > provide a ndo_select_queue() function.
>
> OK, that explains everything. Thank you Eric. I assume it may take some
> time for bonding to become multiqueue aware and/or bnx2x to provide
> ndo_select_queue?
>
bonding might become multiqueue aware, there are several patches
floating around.
But with your ping tests, it wont change the selected txqueue anyway (it
will be the same for any targets, because skb_tx_hash() wont hash the
destination address, only the skb->protocol.
> BTW: With a normal router workload, should I expect big performance drop
> when receiving and forwarding the same packet using different CPUs?
> Bonding provides very important functionality, I'm not able to drop it. :(
>
Not sure what you mean by forwarding same packet using different CPUs.
You probably meant different queues, because in normal case, only one
cpu is involved (the one receiving the packet is also the one
transmitting it, unless you have congestion or trafic shaping)
If you have 4 cpus, you can use following patch and have a transparent
bonding against multiqueue. Still bonding xmit path hits a global
rwlock, so performance is not what you can get without bonding.
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 5e12462..2c257f7 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -5012,8 +5012,8 @@ 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, 4);
if (!bond_dev) {
pr_err("%s: eek! can't alloc netdev!\n", name);
rtnl_unlock();
next prev parent reply other threads:[~2010-05-16 20:47 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-16 13:33 bnx2/BCM5709: why 5 interrupts on a 4 core system (2.6.33.3) Krzysztof Oledzki
2010-05-16 18:51 ` Michael Chan
2010-05-16 19:24 ` Krzysztof Olędzki
2010-05-16 19:49 ` Krzysztof Olędzki
2010-05-16 20:00 ` Michael Chan
2010-05-16 20:15 ` Eric Dumazet
2010-05-16 20:24 ` Michael Chan
2010-05-16 20:34 ` Krzysztof Olędzki
2010-05-16 20:47 ` Eric Dumazet [this message]
2010-05-16 21:06 ` George B.
2010-05-16 21:12 ` Krzysztof Olędzki
2010-05-16 21:26 ` Eric Dumazet
2010-05-18 14:22 ` Krzysztof Olędzki
2010-05-18 14:26 ` Eric Dumazet
2010-05-18 14:55 ` Krzysztof Olędzki
2010-05-18 15:35 ` Krzysztof Olędzki
2010-05-18 2:11 ` Michael Chan
2010-05-18 16:28 ` Krzysztof Olędzki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1274042826.2299.26.camel@edumazet-laptop \
--to=eric.dumazet@gmail.com \
--cc=mchan@broadcom.com \
--cc=netdev@vger.kernel.org \
--cc=ole@ans.pl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).