From: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
To: stable@dpdk.org, Yongseok Koh <yskoh@mellanox.com>,
Luca Boccassi <bluca@debian.org>
Subject: [dpdk-stable] [PATCH] net/mlx5: fix silent error for unsupported flow items
Date: Wed, 18 Jul 2018 10:37:53 +0200 [thread overview]
Message-ID: <efc68c4d2bc63bd24276d178965dc76931ed5ab5.1531903038.git.nelio.laranjeiro@6wind.com> (raw)
Not supported items are causing a silent error which does not stops the
conversion of the flow rule. This silent error ends in case of a flow
create by segmentation fault.
Fixes: 2097d0d1e2cc ("net/mlx5: support basic flow items and actions")
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
---
The commit impacts the following stable branches:
v17.02, v17.05, v17.08, v17.11, v18.02, v18.05
---
drivers/net/mlx5/mlx5_flow.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
index f48b68945..8ebc0928b 100644
--- a/drivers/net/mlx5/mlx5_flow.c
+++ b/drivers/net/mlx5/mlx5_flow.c
@@ -801,8 +801,10 @@ mlx5_flow_convert_items_validate(const struct rte_flow_item items[],
break;
}
}
- if (!token)
+ if (!token) {
+ ret = -ENOTSUP;
goto exit_item_not_supported;
+ }
cur_item = token;
ret = mlx5_flow_item_validate(items,
(const uint8_t *)cur_item->mask,
--
2.18.0
next reply other threads:[~2018-07-18 8:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-18 8:37 Nelio Laranjeiro [this message]
2018-07-27 1:27 ` Yongseok Koh
2018-08-20 6:40 ` Nélio Laranjeiro
2018-08-20 18:48 ` Luca Boccassi
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=efc68c4d2bc63bd24276d178965dc76931ed5ab5.1531903038.git.nelio.laranjeiro@6wind.com \
--to=nelio.laranjeiro@6wind.com \
--cc=bluca@debian.org \
--cc=stable@dpdk.org \
--cc=yskoh@mellanox.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).