aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKamal Heib <[email protected]>2021-12-05 22:45:37 +0200
committerJason Gunthorpe <[email protected]>2021-12-06 19:56:30 -0400
commit0a0575a12e31657415d1d5f799d4b65f3c9e8ba4 (patch)
treeaeb87a9078c728eafc1a9df2f6619067c66dea4a
parentb6fa6f229f7364782799e5105d8d353e389033e4 (diff)
RDMA/bnxt_re: Fix endianness warning for req.pkey
Fix the following sparse warning: drivers/infiniband/hw/bnxt_re/qplib_fp.c:1260:26: sparse: warning: incorrect type in assignment (different base types) Fixes: 0e938533d96d ("RDMA/bnxt_re: Remove dynamic pkey table") Link: https://lore.kernel.org/r/[email protected] Reported-by: kernel test robot <[email protected]> Signed-off-by: Kamal Heib <[email protected]> Reviewed-by: Leon Romanovsky <[email protected]> Acked-by: Selvin Xavier <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
-rw-r--r--drivers/infiniband/hw/bnxt_re/qplib_fp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/bnxt_re/qplib_fp.c b/drivers/infiniband/hw/bnxt_re/qplib_fp.c
index f6472cca9ec7..96e581ced50e 100644
--- a/drivers/infiniband/hw/bnxt_re/qplib_fp.c
+++ b/drivers/infiniband/hw/bnxt_re/qplib_fp.c
@@ -1257,7 +1257,7 @@ int bnxt_qplib_modify_qp(struct bnxt_qplib_res *res, struct bnxt_qplib_qp *qp)
req.access = qp->access;
if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_PKEY)
- req.pkey = IB_DEFAULT_PKEY_FULL;
+ req.pkey = cpu_to_le16(IB_DEFAULT_PKEY_FULL);
if (bmask & CMDQ_MODIFY_QP_MODIFY_MASK_QKEY)
req.qkey = cpu_to_le32(qp->qkey);