Skip to content

Commit

Permalink
IB/mlx5: Clean mlx5_ib_mr_responder_pfault_handler() signature
Browse files Browse the repository at this point in the history
In the function mlx5_ib_mr_responder_pfault_handler()

1. The parameter wqe is used as read-only so there is no need to pass it
   by reference.
2. Remove the unused argument pfault from list of arguments.

Signed-off-by: Moni Shoua <monis@mellanox.com>
Reviewed-by: Majd Dibbiny <majd@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
  • Loading branch information
Moni Shoua authored and Jason Gunthorpe committed Feb 4, 2019
1 parent 586f4e9 commit 6ff7414
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions drivers/infiniband/hw/mlx5/odp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1064,12 +1064,12 @@ static int mlx5_ib_mr_initiator_pfault_handler(
}

/*
* Parse responder WQE. Advances the wqe pointer to point at the
* scatter-gather list, and set wqe_end to the end of the WQE.
* Parse responder WQE and set wqe_end to the end of the WQE.
*/
static int mlx5_ib_mr_responder_pfault_handler(
struct mlx5_ib_dev *dev, struct mlx5_pagefault *pfault,
struct mlx5_ib_qp *qp, void **wqe, void **wqe_end, int wqe_length)
static int mlx5_ib_mr_responder_pfault_handler(struct mlx5_ib_dev *dev,
struct mlx5_ib_qp *qp, void *wqe,
void **wqe_end,
int wqe_length)
{
struct mlx5_ib_wq *wq = &qp->rq;
int wqe_size = 1 << wq->wqe_shift;
Expand Down Expand Up @@ -1102,7 +1102,7 @@ static int mlx5_ib_mr_responder_pfault_handler(
return -EFAULT;
}

*wqe_end = *wqe + wqe_size;
*wqe_end = wqe + wqe_size;

return 0;
}
Expand Down Expand Up @@ -1185,7 +1185,7 @@ static void mlx5_ib_mr_wqe_pfault_handler(struct mlx5_ib_dev *dev,
ret = mlx5_ib_mr_initiator_pfault_handler(dev, pfault, qp, &wqe,
&wqe_end, ret);
else
ret = mlx5_ib_mr_responder_pfault_handler(dev, pfault, qp, &wqe,
ret = mlx5_ib_mr_responder_pfault_handler(dev, qp, wqe,
&wqe_end, ret);
if (ret < 0)
goto resolve_page_fault;
Expand Down

0 comments on commit 6ff7414

Please sign in to comment.