From: Vladyslav Buslov <vladyslav.buslov@harmonicinc.com>
To: <dev@dpdk.org>
Subject: [dpdk-dev] [PATCH] bonding: fix incorrect loop boundary condition
Date: Fri, 1 Apr 2016 15:16:59 +0300 [thread overview]
Message-ID: <1459513019-3826-1-git-send-email-vladyslav.buslov@harmonicinc.com> (raw)
Loop that calculates total number of tx descriptors in slave tx queues should iterate up to nb_tx_queues, not nb_rx_queues.
Signed-off-by: Vladyslav Buslov <vladyslav.buslov@harmonicinc.com>
---
drivers/net/bonding/rte_eth_bond_8023ad.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c
index 1b7e93a..c4448b7 100644
--- a/drivers/net/bonding/rte_eth_bond_8023ad.c
+++ b/drivers/net/bonding/rte_eth_bond_8023ad.c
@@ -890,7 +890,7 @@ bond_mode_8023ad_activate_slave(struct rte_eth_dev *bond_dev, uint8_t slave_id)
/* The size of the mempool should be at least:
* the sum of the TX descriptors + BOND_MODE_8023AX_SLAVE_TX_PKTS */
total_tx_desc = BOND_MODE_8023AX_SLAVE_TX_PKTS;
- for (q_id = 0; q_id < bond_dev->data->nb_rx_queues; q_id++) {
+ for (q_id = 0; q_id < bond_dev->data->nb_tx_queues; q_id++) {
bd_tx_q = (struct bond_tx_queue*)bond_dev->data->tx_queues[q_id];
total_tx_desc += bd_tx_q->nb_tx_desc;
}
--
2.8.0
next reply other threads:[~2016-04-01 12:18 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-01 12:16 Vladyslav Buslov [this message]
2016-04-01 13:28 ` Thomas Monjalon
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=1459513019-3826-1-git-send-email-vladyslav.buslov@harmonicinc.com \
--to=vladyslav.buslov@harmonicinc.com \
--cc=dev@dpdk.org \
/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).