path: root/drivers/net/mlx5/mlx5_rxq.c
diff options
authorMatan Azrad <>2018-08-01 08:37:38 +0000
committerShahaf Shuler <>2018-08-02 12:34:18 +0200
commit2d3b832052dc2a984f527c13a22ecc49082b4ae7 (patch)
tree0a4d61d3b0813898bd605628d5b597702a319561 /drivers/net/mlx5/mlx5_rxq.c
parentc7684b6be4977e7d343b17f798192062b312461d (diff)
net/mlx5: fix packet type offload for tunnels
There are dedicated QP attributes, tunnel offload flag and mask, which must be configured in order to allow part of the HW tunnel offloads. So, if a QP is pointed by a tunnel flow, the above QP attributes should be configured. The mask configuration is wrongly only performed if an internal RSS was configured by the user, while there is no reason to condition the tunnel offloads in RSS configurations. Consequently, some of the tunnel offloads was not performed by the HW when a tunnel flow was configured, for example, the packet tunnel types was not reported to the user. Replace the internal RSS condition with the tunnel flow condition. Fixes: df6afd377ace ("net/mlx5: remove useless arguments in hrxq API") Signed-off-by: Matan Azrad <>
Diffstat (limited to 'drivers/net/mlx5/mlx5_rxq.c')
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/mlx5/mlx5_rxq.c b/drivers/net/mlx5/mlx5_rxq.c
index 16e1641..97b3e8e 100644
--- a/drivers/net/mlx5/mlx5_rxq.c
+++ b/drivers/net/mlx5/mlx5_rxq.c
@@ -1752,7 +1752,8 @@ struct mlx5_hrxq *
mlx5_hrxq_new(struct rte_eth_dev *dev,
const uint8_t *rss_key, uint32_t rss_key_len,
uint64_t hash_fields,
- const uint16_t *queues, uint32_t queues_n)
+ const uint16_t *queues, uint32_t queues_n,
+ int tunnel __rte_unused)
struct priv *priv = dev->data->dev_private;
struct mlx5_hrxq *hrxq;
@@ -1794,9 +1795,8 @@ mlx5_hrxq_new(struct rte_eth_dev *dev,
.pd = priv->pd,
&(struct mlx5dv_qp_init_attr){
- .comp_mask = (hash_fields & IBV_RX_HASH_INNER) ?
- 0,
+ .comp_mask = tunnel ?