Skip to content

Commit

Permalink
IB/rxe: avoid calling WARN_ON_ONCE twice
Browse files Browse the repository at this point in the history
In the exit branch, WARN_ON_ONCE is called to show stack. So it is
not necessary to call WARN_ON_ONCE before going to exit.

Signed-off-by: Zhu Yanjun <yanjun.zhu@oracle.com>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
  • Loading branch information
Zhu Yanjun authored and Jason Gunthorpe committed May 17, 2018
1 parent 5e6e78d commit da2f3b2
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions drivers/infiniband/sw/rxe/rxe_comp.c
Original file line number Diff line number Diff line change
Expand Up @@ -659,7 +659,6 @@ int rxe_completer(void *arg)
qp->qp_timeout_jiffies)
mod_timer(&qp->retrans_timer,
jiffies + qp->qp_timeout_jiffies);
WARN_ON_ONCE(skb);
goto exit;

case COMPST_ERROR_RETRY:
Expand All @@ -673,7 +672,6 @@ int rxe_completer(void *arg)

/* there is nothing to retry in this case */
if (!wqe || (wqe->state == wqe_state_posted)) {
WARN_ON_ONCE(skb);
goto exit;
}

Expand Down Expand Up @@ -702,7 +700,6 @@ int rxe_completer(void *arg)
skb = NULL;
}

WARN_ON_ONCE(skb);
goto exit;

} else {
Expand Down Expand Up @@ -746,7 +743,6 @@ int rxe_completer(void *arg)
skb = NULL;
}

WARN_ON_ONCE(skb);
goto exit;
}
}
Expand Down

0 comments on commit da2f3b2

Please sign in to comment.