net/sfc: fix errno if flow API RSS action parse fails

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

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

Signed-off-by: Roman Zhukov <roman.zhukov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
This commit is contained in:
Roman Zhukov 2018-05-16 15:21:23 +01:00 committed by Ferruh Yigit
parent 2f5045c51c
commit 1613848c2c

View File

@ -1572,7 +1572,7 @@ sfc_flow_parse_actions(struct sfc_adapter *sa,
rc = sfc_flow_parse_rss(sa, actions->conf, flow); rc = sfc_flow_parse_rss(sa, actions->conf, flow);
if (rc != 0) { if (rc != 0) {
rte_flow_error_set(error, rc, rte_flow_error_set(error, -rc,
RTE_FLOW_ERROR_TYPE_ACTION, actions, RTE_FLOW_ERROR_TYPE_ACTION, actions,
"Bad RSS action"); "Bad RSS action");
return -rte_errno; return -rte_errno;