summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2016-11-17 14:00:05 +0300
committerDoug Ledford <dledford@redhat.com>2016-12-12 16:31:45 -0500
commit95db9d05b717b1ec242799103c09acda8d728974 (patch)
tree6381a7596172dfdfb16daae59a16237f43b41745 /drivers/infiniband
parent4ac4707102d9ea1ffc9b5735891f6c5ee3d236e5 (diff)
downloadblackbird-op-linux-95db9d05b717b1ec242799103c09acda8d728974.tar.gz
blackbird-op-linux-95db9d05b717b1ec242799103c09acda8d728974.zip
IB/rxe: Remove unneeded cast in rxe_srq_from_attr()
It makes me nervous when we cast pointer parameters. I would estimate that around 50% of the time, it indicates a bug. Here the cast is not needed becaue u32 and and unsigned int are the same thing. Removing the cast makes the code more robust and future proof in case any of the types change. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Leon Romanovsky <leonro@mellanox.com> Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com> Acked-by: Moni Shoua <monis@mellanox.com> Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/sw/rxe/rxe_srq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/sw/rxe/rxe_srq.c b/drivers/infiniband/sw/rxe/rxe_srq.c
index 2a6e3cd2d4e8..efc832a2d7c6 100644
--- a/drivers/infiniband/sw/rxe/rxe_srq.c
+++ b/drivers/infiniband/sw/rxe/rxe_srq.c
@@ -169,7 +169,7 @@ int rxe_srq_from_attr(struct rxe_dev *rxe, struct rxe_srq *srq,
}
}
- err = rxe_queue_resize(q, (unsigned int *)&attr->max_wr,
+ err = rxe_queue_resize(q, &attr->max_wr,
rcv_wqe_size(srq->rq.max_sge),
srq->rq.queue->ip ?
srq->rq.queue->ip->context :
OpenPOWER on IntegriCloud