From: Usman Tanveer <usman.tanveer@emumba.com>
To: chas3@att.com, humin29@huawei.com
Cc: dev@dpdk.org
Subject: Re: [PATCH v2] net/bonding: fix error in bonding mode 4 with dedicated queues enabled
Date: Thu, 29 Sep 2022 09:16:12 +0500 [thread overview]
Message-ID: <CAH_O0bwAv9yB3EBAp68F5Vk4+HN_xOf+PhNJ5rJP9Wd01UR9Ag@mail.gmail.com> (raw)
In-Reply-To: <20220929040551.120717-1-usman.tanveer@emumba.com>
We cannot configure the queues when the device is started. So, that
part is still before the device starts. I just moved
bond_ethdev_8023ad_flow_set() after the device start.
On Thu, Sep 29, 2022 at 9:05 AM Usman Tanveer <usman.tanveer@emumba.com> wrote:
>
> when dedicated queues are enable with bonding mode 4 (mlx5), the
> application sets the flow, which cannot be set if the device is not
> started. This fixed the issue by starting the device just before
> setting the flow. Because device should be started to set the flow.
> Also it does not effect other driver codes (I have tried on ixgbe).
>
> Bugzilla ID: 759
>
> Signed-off-by: Usman Tanveer <usman.tanveer@emumba.com>
> ---
> drivers/net/bonding/rte_eth_bond_pmd.c | 19 +++++++++++--------
> 1 file changed, 11 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
> index fd2d95a751..69cbbe19ff 100644
> --- a/drivers/net/bonding/rte_eth_bond_pmd.c
> +++ b/drivers/net/bonding/rte_eth_bond_pmd.c
> @@ -1828,7 +1828,18 @@ slave_start(struct rte_eth_dev *bonded_eth_dev,
> RTE_BOND_LOG(ERR, "bond_ethdev_8023ad_flow_destroy: port=%d, err (%d)",
> slave_eth_dev->data->port_id, errval);
> }
> + }
> +
> + /* Start device */
> + errval = rte_eth_dev_start(slave_eth_dev->data->port_id);
> + if (errval != 0) {
> + RTE_BOND_LOG(ERR, "rte_eth_dev_start: port=%u, err (%d)",
> + slave_eth_dev->data->port_id, errval);
> + return -1;
> + }
>
> + if (internals->mode == BONDING_MODE_8023AD &&
> + internals->mode4.dedicated_queues.enabled == 1) {
> errval = bond_ethdev_8023ad_flow_set(bonded_eth_dev,
> slave_eth_dev->data->port_id);
> if (errval != 0) {
> @@ -1839,14 +1850,6 @@ slave_start(struct rte_eth_dev *bonded_eth_dev,
> }
> }
>
> - /* Start device */
> - errval = rte_eth_dev_start(slave_eth_dev->data->port_id);
> - if (errval != 0) {
> - RTE_BOND_LOG(ERR, "rte_eth_dev_start: port=%u, err (%d)",
> - slave_eth_dev->data->port_id, errval);
> - return -1;
> - }
> -
> /* If RSS is enabled for bonding, synchronize RETA */
> if (bonded_eth_dev->data->dev_conf.rxmode.mq_mode & RTE_ETH_MQ_RX_RSS) {
> int i;
> --
> 2.25.1
>
next prev parent reply other threads:[~2022-09-29 4:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-29 4:05 Usman Tanveer
2022-09-29 4:16 ` Usman Tanveer [this message]
2022-10-15 15:28 ` Chas Williams
2022-10-17 8:28 ` Andrew Rybchenko
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=CAH_O0bwAv9yB3EBAp68F5Vk4+HN_xOf+PhNJ5rJP9Wd01UR9Ag@mail.gmail.com \
--to=usman.tanveer@emumba.com \
--cc=chas3@att.com \
--cc=dev@dpdk.org \
--cc=humin29@huawei.com \
/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).