patches for DPDK stable branches
 help / color / mirror / Atom feed
From: "Xueming(Steven) Li" <xuemingl@nvidia.com>
To: Dmitry Kozlyuk <dkozlyuk@nvidia.com>,
	"stable@dpdk.org" <stable@dpdk.org>
Subject: RE: [PATCH 20.11] net/mlx5: destroy indirect actions on port stop
Date: Fri, 12 Aug 2022 07:21:05 +0000	[thread overview]
Message-ID: <DM4PR12MB5373C1F7058C20675B8B5344A1679@DM4PR12MB5373.namprd12.prod.outlook.com> (raw)
In-Reply-To: <20220811073716.3631212-1-dkozlyuk@nvidia.com>

Thanks, applied to 20.11 LTS queue.

> -----Original Message-----
> From: Dmitry Kozlyuk <dkozlyuk@nvidia.com>
> Sent: Thursday, August 11, 2022 3:37 PM
> To: stable@dpdk.org
> Cc: Xueming(Steven) Li <xuemingl@nvidia.com>
> Subject: [PATCH 20.11] net/mlx5: destroy indirect actions on port stop
> 
> [ Upstream commit ec4e11d41d129ebc7c395b567827492e56fb08b7
>   cannot be backported, because it avoids the issue
>   by advertising and using a new capability
>   of keeping indirect actions across restart.
>   The behavior was unspecified before then,
>   so it is correct for 20.11 with this patch
>   to behave differently compared to the upstream. ]
> 
> Shared RSS actions were not destroyed on port stop, preventing release of involved RX queue resources.
> As a result, associated pool of such queues was exhaused after a number of port stop and start operations.
> Diagnostic message from rte_eth_dev_start():
> 
>     Rx queue allocation failed: Cannot allocate memory
> 
> When built with RTE_LIBRTE_MLX5_DEBUG,
> the following assert was triggered:
> 
>     testpmd> port start 0
>     PANIC in mlx5_rxq_start():
>     line 169        assert "!rxq_ctrl->obj" failed
> 
> Destroy indirect actions on port stop to release the resources.
> 
> Fixes: d7cfcddded61 ("net/mlx5: translate shared action for RSS action")
> 
> Signed-off-by: Dmitry Kozlyuk <dkozlyuk@nvidia.com>
> ---
>  drivers/net/mlx5/mlx5_trigger.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/net/mlx5/mlx5_trigger.c b/drivers/net/mlx5/mlx5_trigger.c index 6273122e40..c8dc0398ea 100644
> --- a/drivers/net/mlx5/mlx5_trigger.c
> +++ b/drivers/net/mlx5/mlx5_trigger.c
> @@ -13,6 +13,7 @@
>  #include <mlx5_malloc.h>
> 
>  #include "mlx5.h"
> +#include "mlx5_flow.h"
>  #include "mlx5_mr.h"
>  #include "mlx5_rxtx.h"
>  #include "mlx5_utils.h"
> @@ -1192,6 +1193,7 @@ mlx5_dev_stop(struct rte_eth_dev *dev)
>  	mlx5_traffic_disable(dev);
>  	/* All RX queue flags will be cleared in the flush interface. */
>  	mlx5_flow_list_flush(dev, &priv->flows, true);
> +	mlx5_shared_action_flush(dev);
>  	mlx5_rx_intr_vec_disable(dev);
>  	priv->sh->port[priv->dev_port - 1].ih_port_id = RTE_MAX_ETHPORTS;
>  	priv->sh->port[priv->dev_port - 1].devx_ih_port_id = RTE_MAX_ETHPORTS;
> --
> 2.25.1


      reply	other threads:[~2022-08-12  7:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-11  7:37 Dmitry Kozlyuk
2022-08-12  7:21 ` Xueming(Steven) Li [this message]

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=DM4PR12MB5373C1F7058C20675B8B5344A1679@DM4PR12MB5373.namprd12.prod.outlook.com \
    --to=xuemingl@nvidia.com \
    --cc=dkozlyuk@nvidia.com \
    --cc=stable@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).