From: Raslan Darawsheh <rasland@nvidia.com>
To: "Xueming(Steven) Li" <xuemingl@nvidia.com>,
Matan Azrad <matan@nvidia.com>,
Slava Ovsiienko <viacheslavo@nvidia.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>, Asaf Penso <asafp@nvidia.com>,
"stable@dpdk.org" <stable@dpdk.org>
Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] net/mlx5: disable flow dump for Verbs flow
Date: Tue, 6 Oct 2020 15:24:26 +0000 [thread overview]
Message-ID: <DM6PR12MB2748E31190D815B068A5DB93CF0D0@DM6PR12MB2748.namprd12.prod.outlook.com> (raw)
In-Reply-To: <1599711897-21330-1-git-send-email-xuemingl@nvidia.com>
Hi,
> -----Original Message-----
> From: dev <dev-bounces@dpdk.org> On Behalf Of Xueming Li
> Sent: Thursday, September 10, 2020 7:25 AM
> To: Matan Azrad <matan@nvidia.com>; Slava Ovsiienko
> <viacheslavo@nvidia.com>
> Cc: dev@dpdk.org; Asaf Penso <asafp@nvidia.com>; stable@dpdk.org
> Subject: [dpdk-dev] [PATCH] net/mlx5: disable flow dump for Verbs flow
>
> There was a segment fault when dump flows with device argument of
> dv_flow_en=0. In such case, Verbs flow engine was enabled and fdb
> resources were not initialized. It's suggested to use mlx_fs_dump
> for Verbs flow dump.
>
> This patch adds verbs engine check, prints warning message and return
> gracefully.
>
> Cc: stable@dpdk.org
> Signed-off-by: Xueming Li <xuemingl@nvidia.com>
> ---
> drivers/net/mlx5/mlx5_flow.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
> index 4c29898203..5a28b80ee4 100644
> --- a/drivers/net/mlx5/mlx5_flow.c
> +++ b/drivers/net/mlx5/mlx5_flow.c
> @@ -6268,6 +6268,11 @@ mlx5_flow_dev_dump(struct rte_eth_dev *dev,
> struct mlx5_priv *priv = dev->data->dev_private;
> struct mlx5_dev_ctx_shared *sh = priv->sh;
>
> + if (!priv->config.dv_flow_en) {
> + if (fputs("device dv flow disabled\n", file) <= 0)
> + return -errno;
> + return -ENOTSUP;
> + }
> return mlx5_devx_cmd_flow_dump(sh->fdb_domain, sh-
> >rx_domain,
> sh->tx_domain, file);
> }
> --
> 2.25.1
Patch applied to next-net-mlx,
Kindest regards,
Raslan Darawsheh
next prev parent reply other threads:[~2020-10-06 15:24 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-10 4:24 [dpdk-stable] " Xueming Li
2020-10-06 8:46 ` [dpdk-stable] [dpdk-dev] " Viacheslav Ovsiienko
2020-10-06 15:24 ` Raslan Darawsheh [this message]
2020-10-07 9:56 ` Ferruh Yigit
2020-10-08 12:09 ` Raslan Darawsheh
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=DM6PR12MB2748E31190D815B068A5DB93CF0D0@DM6PR12MB2748.namprd12.prod.outlook.com \
--to=rasland@nvidia.com \
--cc=asafp@nvidia.com \
--cc=dev@dpdk.org \
--cc=matan@nvidia.com \
--cc=stable@dpdk.org \
--cc=viacheslavo@nvidia.com \
--cc=xuemingl@nvidia.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).