aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx5/main.c
diff options
context:
space:
mode:
authorMatan Barak <matanb@mellanox.com>2018-03-28 02:27:55 -0400
committerJason Gunthorpe <jgg@mellanox.com>2018-04-04 14:06:28 -0400
commit2d93fc856959bb940b3cf1e7cbad38721d6bea75 (patch)
tree78cbf6275d037224778eb6ee6256e52bd30982e1 /drivers/infiniband/hw/mlx5/main.c
parentc03faa562d0279e463900c92d4a54c0dc3c806b0 (diff)
IB/mlx5: Add ability to hash by IPSEC_SPI when creating a TIR
When a Raw Ethernet QP is created, we actually create a few objects. One of these objects is a TIR. Currently, a TIR could hash (and spread the traffic) by IP or port only. Adding a hashing by IPSec SPI to TIR creation with the required UAPI bit. Signed-off-by: Matan Barak <matanb@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/mlx5/main.c')
-rw-r--r--drivers/infiniband/hw/mlx5/main.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/mlx5/main.c b/drivers/infiniband/hw/mlx5/main.c
index 25e70ae0b484..31295e39896c 100644
--- a/drivers/infiniband/hw/mlx5/main.c
+++ b/drivers/infiniband/hw/mlx5/main.c
@@ -856,6 +856,10 @@ static int mlx5_ib_query_device(struct ib_device *ibdev,
856 MLX5_RX_HASH_SRC_PORT_UDP | 856 MLX5_RX_HASH_SRC_PORT_UDP |
857 MLX5_RX_HASH_DST_PORT_UDP | 857 MLX5_RX_HASH_DST_PORT_UDP |
858 MLX5_RX_HASH_INNER; 858 MLX5_RX_HASH_INNER;
859 if (mlx5_accel_ipsec_device_caps(dev->mdev) &
860 MLX5_ACCEL_IPSEC_CAP_DEVICE)
861 resp.rss_caps.rx_hash_fields_mask |=
862 MLX5_RX_HASH_IPSEC_SPI;
859 resp.response_length += sizeof(resp.rss_caps); 863 resp.response_length += sizeof(resp.rss_caps);
860 } 864 }
861 } else { 865 } else {