aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mthca/mthca_dev.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/infiniband/hw/mthca/mthca_dev.h')
-rw-r--r--drivers/infiniband/hw/mthca/mthca_dev.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_dev.h b/drivers/infiniband/hw/mthca/mthca_dev.h
index 33162a960c7..3519ca4e086 100644
--- a/drivers/infiniband/hw/mthca/mthca_dev.h
+++ b/drivers/infiniband/hw/mthca/mthca_dev.h
@@ -333,14 +333,13 @@ extern void __buggy_use_of_MTHCA_PUT(void);
333 333
334#define MTHCA_PUT(dest, source, offset) \ 334#define MTHCA_PUT(dest, source, offset) \
335 do { \ 335 do { \
336 __typeof__(source) *__p = \ 336 void *__d = ((char *) (dest) + (offset)); \
337 (__typeof__(source) *) ((char *) (dest) + (offset)); \
338 switch (sizeof(source)) { \ 337 switch (sizeof(source)) { \
339 case 1: *__p = (source); break; \ 338 case 1: *(u8 *) __d = (source); break; \
340 case 2: *__p = cpu_to_be16(source); break; \ 339 case 2: *(__be16 *) __d = cpu_to_be16(source); break; \
341 case 4: *__p = cpu_to_be32(source); break; \ 340 case 4: *(__be32 *) __d = cpu_to_be32(source); break; \
342 case 8: *__p = cpu_to_be64(source); break; \ 341 case 8: *(__be64 *) __d = cpu_to_be64(source); break; \
343 default: __buggy_use_of_MTHCA_PUT(); \ 342 default: __buggy_use_of_MTHCA_PUT(); \
344 } \ 343 } \
345 } while (0) 344 } while (0)
346 345
@@ -435,7 +434,7 @@ int mthca_arbel_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr,
435int mthca_arbel_post_receive(struct ib_qp *ibqp, struct ib_recv_wr *wr, 434int mthca_arbel_post_receive(struct ib_qp *ibqp, struct ib_recv_wr *wr,
436 struct ib_recv_wr **bad_wr); 435 struct ib_recv_wr **bad_wr);
437int mthca_free_err_wqe(struct mthca_dev *dev, struct mthca_qp *qp, int is_send, 436int mthca_free_err_wqe(struct mthca_dev *dev, struct mthca_qp *qp, int is_send,
438 int index, int *dbd, u32 *new_wqe); 437 int index, int *dbd, __be32 *new_wqe);
439int mthca_alloc_qp(struct mthca_dev *dev, 438int mthca_alloc_qp(struct mthca_dev *dev,
440 struct mthca_pd *pd, 439 struct mthca_pd *pd,
441 struct mthca_cq *send_cq, 440 struct mthca_cq *send_cq,