From: Alexander Kozyrev <akozyrev@nvidia.com>
To: <dev@dpdk.org>
Cc: <rasland@nvidia.com>, <viacheslavo@nvidia.com>, <matan@nvidia.com>
Subject: [dpdk-dev] [PATCH] net/mlx5: do not allow copy to mark via modify field
Date: Wed, 16 Jun 2021 21:34:44 +0300 [thread overview]
Message-ID: <20210616183444.2815030-1-akozyrev@nvidia.com> (raw)
Mark requires a tag resource to be registered as part of
the value assigning. It is not possible during a copy
operation from a packet field. Forbid this in MODIFY_FIELD.
Signed-off-by: Alexander Kozyrev <akozyrev@nvidia.com>
---
drivers/net/mlx5/mlx5_flow_dv.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index dafd37ab93..26b901e32e 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -4797,10 +4797,11 @@ flow_dv_validate_action_modify_field(struct rte_eth_dev *dev,
"source and destination fields"
" cannot be the same");
if (action_modify_field->dst.field == RTE_FLOW_FIELD_VALUE ||
- action_modify_field->dst.field == RTE_FLOW_FIELD_POINTER)
+ action_modify_field->dst.field == RTE_FLOW_FIELD_POINTER ||
+ action_modify_field->dst.field == RTE_FLOW_FIELD_MARK)
return rte_flow_error_set(error, EINVAL,
RTE_FLOW_ERROR_TYPE_ACTION, action,
- "immediate value or a pointer to it"
+ "mark, immediate value or a pointer to it"
" cannot be used as a destination");
if (action_modify_field->dst.field == RTE_FLOW_FIELD_START ||
action_modify_field->src.field == RTE_FLOW_FIELD_START)
--
2.18.2
next reply other threads:[~2021-06-16 18:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-16 18:34 Alexander Kozyrev [this message]
2021-07-14 6:30 ` [dpdk-dev] [PATCH] net/mlx5: do not allow copy to mark via modify field Slava Ovsiienko
2021-07-16 8:43 ` [dpdk-dev] [PATCH v2] " Alexander Kozyrev
2021-07-16 10:47 ` Slava Ovsiienko
2021-07-22 14:28 ` Thomas Monjalon
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=20210616183444.2815030-1-akozyrev@nvidia.com \
--to=akozyrev@nvidia.com \
--cc=dev@dpdk.org \
--cc=matan@nvidia.com \
--cc=rasland@nvidia.com \
--cc=viacheslavo@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.