DPDK patches and discussions
 help / color / mirror / Atom feed
From: Chaoyong He <chaoyong.he@corigine.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "dev@dpdk.org" <dev@dpdk.org>, oss-drivers <oss-drivers@corigine.com>
Subject: RE: [PATCH 0/2] add function to set dedicated queue size
Date: Thu, 6 Jun 2024 01:41:04 +0000	[thread overview]
Message-ID: <PH0PR13MB5568E0DC4EB102E122EEF3339EFA2@PH0PR13MB5568.namprd13.prod.outlook.com> (raw)
In-Reply-To: <20240605085704.137e8e3e@hermes.local>

> On Wed,  5 Jun 2024 13:55:18 +0800
> Chaoyong He <chaoyong.he@corigine.com> wrote:
> 
> > This patch series mainly add a function to bonding PMD to set
> > dedicated queue size, also add a command to testpmd application to
> > invoke this function.
> >
> > At the same time, standard the log message of bonding PMD.
> >
> > Long Wu (2):
> >   net/bonding: standard the log message
> >   net/bonding: add command to set dedicated queue size
> >
> >  .../link_bonding_poll_mode_drv_lib.rst        |   8 ++
> >  doc/guides/rel_notes/release_24_07.rst        |   4 +
> >  drivers/net/bonding/bonding_testpmd.c         | 126 ++++++++++++++----
> >  drivers/net/bonding/eth_bond_8023ad_private.h |   3 +
> >  drivers/net/bonding/rte_eth_bond_8023ad.c     |  39 ++++++
> >  drivers/net/bonding/rte_eth_bond_8023ad.h     |  23 ++++
> >  drivers/net/bonding/rte_eth_bond_pmd.c        |   6 +-
> >  drivers/net/bonding/version.map               |   1 +
> >  8 files changed, 185 insertions(+), 25 deletions(-)
> >
> 
> This is confusing.
> The patch goes to all the effort to configure rx_queue_size but it is never
> actually used in the driver.

We do used it in the function 'member_configure_slow_queue()' of file 'drivers/net/bonding/rte_eth_bond_pmd.c'.

The original logic hardcodes the value of dedicated hardware Rx/Tx queue size into (128/512) and this will cause the
bonding port start fail if the NIC requires more Rx/Tx descriptors than the hardcoded number.

And this is the situation for our NFP card:
```
testpmd> port stop all
testpmd> create bonding device 4 0
testpmd> set bonding balance_xmit_policy 2 l34
testpmd> add bonding member 0 2
testpmd> add bonding member 1 2
testpmd> set bonding lacp dedicated_queues 2 enable
testpmd> show bonding config 2
testpmd> port start 2
Configuring Port 2 (socket 0)
ETHDEV: Device with port_id=0 already stopped
ETHDEV: Device with port_id=1 already stopped
ETHDEV: Device with port_id=0 already stopped
ETHDEV: Invalid value for nb_rx_desc(=128), should be: <= 32768, >= 512, and a product of 128
member_configure_slow_queue(1699) - rte_eth_rx_queue_setup: port=0 queue_id 1, err (-22)
ETHDEV: Device with port_id=1 already stopped
ETHDEV: Invalid value for nb_rx_desc(=128), should be: <= 32768, >= 512, and a product of 128
member_configure_slow_queue(1699) - rte_eth_rx_queue_setup: port=1 queue_id 1, err (-22)
Port 2: 88:3C:C5:A0:32:46
Checking link statuses...
Done
```

And if apply this patch and configure the 'rx_queue_size', then we can start the bonding port successfully.

  reply	other threads:[~2024-06-06  1:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-05  5:55 Chaoyong He
2024-06-05  5:55 ` [PATCH 1/2] net/bonding: standard the log message Chaoyong He
2024-06-05  5:55 ` [PATCH 2/2] net/bonding: add command to set dedicated queue size Chaoyong He
2024-06-05 15:57 ` [PATCH 0/2] add function " Stephen Hemminger
2024-06-06  1:41   ` Chaoyong He [this message]
2024-06-24  2:03 Chaoyong He

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=PH0PR13MB5568E0DC4EB102E122EEF3339EFA2@PH0PR13MB5568.namprd13.prod.outlook.com \
    --to=chaoyong.he@corigine.com \
    --cc=dev@dpdk.org \
    --cc=oss-drivers@corigine.com \
    --cc=stephen@networkplumber.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).