Skip to content

Commit

Permalink
IB/iser: Micro-optimize iser_handle_wc
Browse files Browse the repository at this point in the history
Use likely() for wc.status == IB_WC_SUCCESS

Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
  • Loading branch information
Sagi Grimberg authored and Roland Dreier committed Dec 16, 2014
1 parent 60e2090 commit 06c7fb6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/infiniband/ulp/iser/iser_verbs.c
Original file line number Diff line number Diff line change
Expand Up @@ -1230,7 +1230,7 @@ static void iser_handle_wc(struct ib_wc *wc)
struct iser_rx_desc *rx_desc;

ib_conn = wc->qp->qp_context;
if (wc->status == IB_WC_SUCCESS) {
if (likely(wc->status == IB_WC_SUCCESS)) {
if (wc->opcode == IB_WC_RECV) {
rx_desc = (struct iser_rx_desc *)(uintptr_t)wc->wr_id;
iser_rcv_completion(rx_desc, wc->byte_len,
Expand Down

0 comments on commit 06c7fb6

Please sign in to comment.