diff mbox series

[7/7] net/sfc: ignore direction attributes in transfer flows

Message ID 20211025110415.20683-7-ivan.malov@oktetlabs.ru (mailing list archive)
State Accepted, archived
Delegated to: Ferruh Yigit
Headers show
Series [1/7] net/sfc: do not allow flow rules to refer to VF representors | expand

Checks

Context Check Description
ci/iol-aarch64-unit-testing success Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-spell-check-testing warning Testing issues
ci/intel-Testing success Testing PASS
ci/github-robot: build success github build: passed
ci/Intel-compilation fail Compilation issues
ci/checkpatch success coding style OK

Commit Message

Ivan Malov Oct. 25, 2021, 11:04 a.m. UTC
[1] has deprecated the use of direction attributes in "transfer"
flows. Ignore them during the transition period.

[1] commit 9d2a349b388a ("ethdev: deprecate direction attributes
in transfer flows")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
---
 drivers/net/sfc/sfc_flow.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/drivers/net/sfc/sfc_flow.c b/drivers/net/sfc/sfc_flow.c
index be2dfe778a..fc74c8035e 100644
--- a/drivers/net/sfc/sfc_flow.c
+++ b/drivers/net/sfc/sfc_flow.c
@@ -1252,13 +1252,13 @@  sfc_flow_parse_attr(struct sfc_adapter *sa,
 				   "Groups are not supported");
 		return -rte_errno;
 	}
-	if (attr->egress != 0) {
+	if (attr->egress != 0 && attr->transfer == 0) {
 		rte_flow_error_set(error, ENOTSUP,
 				   RTE_FLOW_ERROR_TYPE_ATTR_EGRESS, attr,
 				   "Egress is not supported");
 		return -rte_errno;
 	}
-	if (attr->ingress == 0) {
+	if (attr->ingress == 0 && attr->transfer == 0) {
 		rte_flow_error_set(error, ENOTSUP,
 				   RTE_FLOW_ERROR_TYPE_ATTR_INGRESS, attr,
 				   "Ingress is compulsory");