diff options
author | Or Gerlitz <ogerlitz@mellanox.com> | 2017-11-12 16:15:10 +0300 |
---|---|---|
committer | Saeed Mahameed <saeedm@mellanox.com> | 2018-01-09 08:40:48 +0300 |
commit | 18e568c390c61682e747178f136bcbc45c707882 (patch) | |
tree | b0df11b1703e5ebf62b49819f99c5231fb74b1b7 /include/linux/mlx5 | |
parent | 40817cdbb695de49fb1bfe857b0f440541cb22d8 (diff) | |
download | linux-18e568c390c61682e747178f136bcbc45c707882.tar.xz |
net/mlx5: Hairpin pair core object setup
Low level code to setup hairpin pair core object, deals with:
- create hairpin RQs/SQs
- destroy hairpin RQs/SQs
- modifying hairpin RQs/SQs - pairing (rst2rdy) and unpairing (rdy2rst)
Unlike conventional RQs/SQs, the memory used for the packet and descriptor
buffers is allocated by the firmware and not the driver. The driver sets
the overall data size (log).
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to 'include/linux/mlx5')
-rw-r--r-- | include/linux/mlx5/transobj.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/mlx5/transobj.h b/include/linux/mlx5/transobj.h index 88441f5ece25..a228310c1968 100644 --- a/include/linux/mlx5/transobj.h +++ b/include/linux/mlx5/transobj.h @@ -75,4 +75,23 @@ int mlx5_core_modify_rqt(struct mlx5_core_dev *dev, u32 rqtn, u32 *in, int inlen); void mlx5_core_destroy_rqt(struct mlx5_core_dev *dev, u32 rqtn); +struct mlx5_hairpin_params { + u8 log_data_size; + u16 q_counter; +}; + +struct mlx5_hairpin { + struct mlx5_core_dev *func_mdev; + struct mlx5_core_dev *peer_mdev; + + u32 rqn; + u32 sqn; +}; + +struct mlx5_hairpin * +mlx5_core_hairpin_create(struct mlx5_core_dev *func_mdev, + struct mlx5_core_dev *peer_mdev, + struct mlx5_hairpin_params *params); + +void mlx5_core_hairpin_destroy(struct mlx5_hairpin *pair); #endif /* __TRANSOBJ_H__ */ |