From: Roman Zhukov <roman.zhu...@oktetlabs.ru>

The value of rte_errno must be positive in case of an error.

Fixes: d77d07391d4d ("net/sfc: support flow API RSS action")
Cc: sta...@dpdk.org

Signed-off-by: Roman Zhukov <roman.zhu...@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybche...@solarflare.com>
---
 drivers/net/sfc/sfc_flow.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/sfc/sfc_flow.c b/drivers/net/sfc/sfc_flow.c
index e6b2ecff4..b15c937b9 100644
--- a/drivers/net/sfc/sfc_flow.c
+++ b/drivers/net/sfc/sfc_flow.c
@@ -1572,7 +1572,7 @@ sfc_flow_parse_actions(struct sfc_adapter *sa,
 
                        rc = sfc_flow_parse_rss(sa, actions->conf, flow);
                        if (rc != 0) {
-                               rte_flow_error_set(error, rc,
+                               rte_flow_error_set(error, -rc,
                                        RTE_FLOW_ERROR_TYPE_ACTION, actions,
                                        "Bad RSS action");
                                return -rte_errno;
-- 
2.17.0

Reply via email to