RDMA/rxe: Fix style warnings
authorBob Pearson <rpearsonhpe@gmail.com>
Thu, 20 Aug 2020 22:46:23 +0000 (17:46 -0500)
committerJason Gunthorpe <jgg@nvidia.com>
Thu, 27 Aug 2020 12:51:08 +0000 (09:51 -0300)
Fixed several minor checkpatch warnings in existing rxe source.

Link: https://lore.kernel.org/r/20200820224638.3212-3-rpearson@hpe.com
Signed-off-by: Bob Pearson <rpearson@hpe.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/sw/rxe/rxe_comp.c
drivers/infiniband/sw/rxe/rxe_net.c
drivers/infiniband/sw/rxe/rxe_qp.c
drivers/infiniband/sw/rxe/rxe_task.h
include/uapi/rdma/rdma_user_rxe.h

index 4bc88708b355885b3f429e75af0dc3cb1975cd90..8e28ebb42fce42ea7af5935f9bfe4c0b177d5ad1 100644 (file)
@@ -690,9 +690,8 @@ int rxe_completer(void *arg)
                         */
 
                        /* there is nothing to retry in this case */
-                       if (!wqe || (wqe->state == wqe_state_posted)) {
+                       if (!wqe || (wqe->state == wqe_state_posted))
                                goto exit;
-                       }
 
                        /* if we've started a retry, don't start another
                         * retry sequence, unless this is a timeout.
index 0c3808611f9508508fd8d6fafe0cb078450e81ba..80abd417f2b968d95b90af9067a6479149815ac0 100644 (file)
@@ -120,7 +120,7 @@ static struct dst_entry *rxe_find_route6(struct net_device *ndev,
        ndst = ipv6_stub->ipv6_dst_lookup_flow(sock_net(recv_sockets.sk6->sk),
                                               recv_sockets.sk6->sk, &fl6,
                                               NULL);
-       if (unlikely(IS_ERR(ndst))) {
+       if (IS_ERR(ndst)) {
                pr_err_ratelimited("no route to %pI6\n", daddr);
                return NULL;
        }
index 6c11c3aeeca6e6effdc7450dbdaa296117f9a7d0..3562b3876101b6cfd391d8e4ac419c714829e3aa 100644 (file)
@@ -628,9 +628,8 @@ int rxe_qp_from_attr(struct rxe_qp *qp, struct ib_qp_attr *attr, int mask,
        if (mask & IB_QP_QKEY)
                qp->attr.qkey = attr->qkey;
 
-       if (mask & IB_QP_AV) {
+       if (mask & IB_QP_AV)
                rxe_init_av(&attr->ah_attr, &qp->pri_av);
-       }
 
        if (mask & IB_QP_ALT_PATH) {
                rxe_init_av(&attr->alt_ah_attr, &qp->alt_av);
index 08ff42d451c621f98ba60595b1c8566effe0334f..66af2f92358b7dd92a2bb6ddbb016fe6b303c4bd 100644 (file)
@@ -60,7 +60,7 @@ struct rxe_task {
 /*
  * init rxe_task structure
  *     arg  => parameter to pass to fcn
- *     fcn  => function to call until it returns != 0
+ *     func => function to call until it returns != 0
  */
 int rxe_init_task(void *obj, struct rxe_task *task,
                  void *arg, int (*func)(void *), char *name);
index aae2e696bb381eacbeaf15bc16e3eda36b5c355d..d8f2e0e46daba7c3fd2bf3789ec8bc793c7cebce 100644 (file)
@@ -99,8 +99,8 @@ struct rxe_send_wr {
                                struct ib_mr *mr;
                                __aligned_u64 reserved;
                        };
-                       __u32        key;
-                       __u32        access;
+                       __u32        key;
+                       __u32        access;
                } reg;
        } wr;
 };
@@ -112,7 +112,7 @@ struct rxe_sge {
 };
 
 struct mminfo {
-       __aligned_u64           offset;
+       __aligned_u64           offset;
        __u32                   size;
        __u32                   pad;
 };