From: NĂ©lio Laranjeiro Date: Thu, 15 Jun 2017 08:25:16 +0000 (+0200) Subject: net/mlx5: fix creation of drop flows X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=6eddd9d65b766cde3ac34f5d733a34258de9017e;p=dpdk.git net/mlx5: fix creation of drop flows Drop flows being created when the port is stop should not access to the drop table hash queues as it is invalid. Fixes: 028761059aeb ("net/mlx5: use an RSS drop queue") Cc: stable@dpdk.org Signed-off-by: Nelio Laranjeiro Acked-by: Shahaf Shuler --- diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index bbfa85c2f0..b7b7c8356c 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -1015,7 +1015,6 @@ priv_flow_create_action_queue_drop(struct priv *priv, return NULL; } rte_flow->drop = 1; - rte_flow->qp = priv->flow_drop_queue->qp; #ifdef HAVE_VERBS_IBV_EXP_FLOW_SPEC_ACTION_DROP drop = (void *)((uintptr_t)flow->ibv_attr + flow->offset); *drop = (struct ibv_exp_flow_spec_action_drop){ @@ -1028,6 +1027,7 @@ priv_flow_create_action_queue_drop(struct priv *priv, rte_flow->ibv_attr = flow->ibv_attr; if (!priv->started) return rte_flow; + rte_flow->qp = priv->flow_drop_queue->qp; rte_flow->ibv_flow = ibv_exp_create_flow(rte_flow->qp, rte_flow->ibv_attr); if (!rte_flow->ibv_flow) {