From 643456761d7557d183ba3195049eeaebfd5c687e Mon Sep 17 00:00:00 2001 From: =?utf8?q?N=C3=A9lio=20Laranjeiro?= Date: Mon, 23 Oct 2017 13:17:55 +0200 Subject: [PATCH] net/mlx5: fix flow priority for queue action Priority is wrongly configured when the action is queue, using the Ethernet layer priority instead of the most specific layer found. Fixes: 8086cf08b2f0 ("net/mlx5: handle RSS hash configuration in RSS flow") Signed-off-by: Nelio Laranjeiro Acked-by: Yongseok Koh --- drivers/net/mlx5/mlx5_flow.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 2b6380fb9c..440bda9a12 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -1172,8 +1172,18 @@ priv_flow_convert(struct priv *priv, * Last step. Complete missing specification to reach the RSS * configuration. */ - if (parser->queues_n > 1) + if (parser->queues_n > 1) { priv_flow_convert_finalise(priv, parser); + } else if (!parser->drop) { + /* + * Action queue have their priority overridden with + * Ethernet priority, this priority needs to be adjusted to + * their most specific layer priority. + */ + parser->queue[HASH_RXQ_ETH].ibv_attr->priority = + attr->priority + + hash_rxq_init[parser->layer].flow_priority; + } exit_free: /* Only verification is expected, all resources should be released. */ if (!parser->create) { -- 2.20.1