diff options
author | Moni Shoua <monis@mellanox.com> | 2018-11-08 22:10:10 +0300 |
---|---|---|
committer | Leon Romanovsky <leonro@mellanox.com> | 2018-11-12 23:20:29 +0300 |
commit | 27e95603f4dfec470c6d26bea5174aa71b30e971 (patch) | |
tree | 7e8a2a7d6c5d71ecd3a88e302607352220c4edea /include/linux/mlx5/qp.h | |
parent | 698114968a22f6c0c9f42e983ba033cc36bb7217 (diff) | |
download | linux-27e95603f4dfec470c6d26bea5174aa71b30e971.tar.xz |
net/mlx5: Add interface to hold and release core resources
Sometimes upper layers may want to prevent the destruction of a core
resource for a period of time while work on that resource is in
progress. Add API to support this.
Signed-off-by: Moni Shoua <monis@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Diffstat (limited to 'include/linux/mlx5/qp.h')
-rw-r--r-- | include/linux/mlx5/qp.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/mlx5/qp.h b/include/linux/mlx5/qp.h index fbe322c966bc..b26ea9077384 100644 --- a/include/linux/mlx5/qp.h +++ b/include/linux/mlx5/qp.h @@ -596,6 +596,11 @@ int mlx5_core_dealloc_q_counter(struct mlx5_core_dev *dev, u16 counter_id); int mlx5_core_query_q_counter(struct mlx5_core_dev *dev, u16 counter_id, int reset, void *out, int out_size); +struct mlx5_core_rsc_common *mlx5_core_res_hold(struct mlx5_core_dev *dev, + int res_num, + enum mlx5_res_type res_type); +void mlx5_core_res_put(struct mlx5_core_rsc_common *res); + static inline const char *mlx5_qp_type_str(int type) { switch (type) { |