diff mbox

[for-next] RDMA/mlx5: Remove set but not used variables

Message ID 20180718210532.14625-1-kamalheib1@gmail.com (mailing list archive)
State Accepted
Delegated to: Jason Gunthorpe
Headers show

Commit Message

Kamal Heib July 18, 2018, 9:05 p.m. UTC
Remove "uctx" and "pa" variables that were set but not used.

Fixes: a8b92ca1b0e5 ("IB/mlx5: Introduce DEVX")
Fixes: 8f0622873358 ("RDMA/mlx5: Remove debug prints of VMA pointers")
Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
---
 drivers/infiniband/hw/mlx5/devx.c | 2 --
 drivers/infiniband/hw/mlx5/main.c | 4 +---
 2 files changed, 1 insertion(+), 5 deletions(-)

Comments

Leon Romanovsky July 23, 2018, 12:58 p.m. UTC | #1
On Thu, Jul 19, 2018 at 12:05:32AM +0300, Kamal Heib wrote:
> Remove "uctx" and "pa" variables that were set but not used.
>
> Fixes: a8b92ca1b0e5 ("IB/mlx5: Introduce DEVX")
> Fixes: 8f0622873358 ("RDMA/mlx5: Remove debug prints of VMA pointers")
> Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
> ---
>  drivers/infiniband/hw/mlx5/devx.c | 2 --
>  drivers/infiniband/hw/mlx5/main.c | 4 +---
>  2 files changed, 1 insertion(+), 5 deletions(-)
>

Thanks,
Acked-by: Leon Romanovsky <leonro@mellanox.com>
Jason Gunthorpe July 23, 2018, 9:39 p.m. UTC | #2
On Thu, Jul 19, 2018 at 12:05:32AM +0300, Kamal Heib wrote:
> Remove "uctx" and "pa" variables that were set but not used.
> 
> Fixes: a8b92ca1b0e5 ("IB/mlx5: Introduce DEVX")
> Fixes: 8f0622873358 ("RDMA/mlx5: Remove debug prints of VMA pointers")
> Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
> Acked-by: Leon Romanovsky <leonro@mellanox.com>
> ---
>  drivers/infiniband/hw/mlx5/devx.c | 2 --
>  drivers/infiniband/hw/mlx5/main.c | 4 +---
>  2 files changed, 1 insertion(+), 5 deletions(-)

applied to for-next

Thanks,
Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/infiniband/hw/mlx5/devx.c b/drivers/infiniband/hw/mlx5/devx.c
index 60ac1fbe940e..7f9d73b03421 100644
--- a/drivers/infiniband/hw/mlx5/devx.c
+++ b/drivers/infiniband/hw/mlx5/devx.c
@@ -50,11 +50,9 @@  int mlx5_ib_devx_create(struct mlx5_ib_dev *dev, struct mlx5_ib_ucontext *contex
 	u32 in[MLX5_ST_SZ_DW(create_uctx_in)] = {0};
 	u32 out[MLX5_ST_SZ_DW(general_obj_out_cmd_hdr)] = {0};
 	u64 general_obj_types;
-	void *uctx;
 	void *hdr;
 	int err;
 
-	uctx = MLX5_ADDR_OF(create_uctx_in, in, uctx);
 	hdr = MLX5_ADDR_OF(create_uctx_in, in, hdr);
 
 	general_obj_types = MLX5_CAP_GEN_64(dev->mdev, general_obj_types);
diff --git a/drivers/infiniband/hw/mlx5/main.c b/drivers/infiniband/hw/mlx5/main.c
index b7f94bc3811a..d4d894e9f942 100644
--- a/drivers/infiniband/hw/mlx5/main.c
+++ b/drivers/infiniband/hw/mlx5/main.c
@@ -2041,7 +2041,7 @@  static int uar_mmap(struct mlx5_ib_dev *dev, enum mlx5_ib_mmap_cmd cmd,
 	struct mlx5_bfreg_info *bfregi = &context->bfregi;
 	int err;
 	unsigned long idx;
-	phys_addr_t pfn, pa;
+	phys_addr_t pfn;
 	pgprot_t prot;
 	u32 bfreg_dyn_idx = 0;
 	u32 uar_index;
@@ -2132,8 +2132,6 @@  static int uar_mmap(struct mlx5_ib_dev *dev, enum mlx5_ib_mmap_cmd cmd,
 		goto err;
 	}
 
-	pa = pfn << PAGE_SHIFT;
-
 	err = mlx5_ib_set_vma_data(vma, context);
 	if (err)
 		goto err;