Skip to contentSkip to conversation

IB/mlx5: Remove dead code

PATCH Applied Leon Romanovsky 2 participants 2 messages Oct 20, 2019 – Oct 22, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 IB/mlx5: Remove dead code

From: Ran Rozenstein <[email protected]>

mlx5_ib_dc_atomic_is_supported function is not used anywhere. Remove the dead code.

Fixes a60109dc9a95 ("IB/mlx5: Add support for extended atomic operations")
---
 drivers/infiniband/hw/mlx5/main.c    | 15 ---------------
 drivers/infiniband/hw/mlx5/mlx5_ib.h |  1 -
 2 files changed, 16 deletions(-)
drivers/infiniband/hw/mlx5/main.c +0 -15
index 27255f68b2fb..fd3dd4523a22 100644
@@ -694,21 +694,6 @@ static void get_atomic_caps_qp(struct mlx5_ib_dev *dev,
 	get_atomic_caps(dev, atomic_size_qp, props);
 }
 
-static void get_atomic_caps_dc(struct mlx5_ib_dev *dev,
-			       struct ib_device_attr *props)
-{
-	u8 atomic_size_qp = MLX5_CAP_ATOMIC(dev->mdev, atomic_size_dc);
-
-	get_atomic_caps(dev, atomic_size_qp, props);
-}
-
-bool mlx5_ib_dc_atomic_is_supported(struct mlx5_ib_dev *dev)
-{
-	struct ib_device_attr props = {};
-
-	get_atomic_caps_dc(dev, &props);
-	return (props.atomic_cap == IB_ATOMIC_HCA) ? true : false;
-}
 static int mlx5_query_system_image_guid(struct ib_device *ibdev,
 					__be64 *sys_image_guid)
 {
drivers/infiniband/hw/mlx5/mlx5_ib.h +0 -1
index d5c80aa9efb1..d925ce0e46b5 100644
@@ -1239,7 +1239,6 @@ struct ib_rwq_ind_table *mlx5_ib_create_rwq_ind_table(struct ib_device *device,
 						      struct ib_rwq_ind_table_init_attr *init_attr,
 						      struct ib_udata *udata);
 int mlx5_ib_destroy_rwq_ind_table(struct ib_rwq_ind_table *wq_ind_table);
-bool mlx5_ib_dc_atomic_is_supported(struct mlx5_ib_dev *dev);
 struct ib_dm *mlx5_ib_alloc_dm(struct ib_device *ibdev,
 			       struct ib_ucontext *context,
 			       struct ib_dm_alloc_attr *attr,
Signature · 1 line
2.20.1
#1 lore raw
Quoted 5 lines · Leon Romanovsky

From: Ran Rozenstein <[email protected]>

mlx5_ib_dc_atomic_is_supported function is not used anywhere. Remove the dead code.

Quoted 8 lines
Fixes a60109dc9a95 ("IB/mlx5: Add support for extended atomic operations")
---
 drivers/infiniband/hw/mlx5/main.c    | 15 ---------------
 drivers/infiniband/hw/mlx5/mlx5_ib.h |  1 -
 2 files changed, 16 deletions(-)

Applied to for-next, thanks

Jason