diff options
author | Max Gurtovoy <maxg@mellanox.com> | 2018-06-27 14:58:02 +0300 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2018-07-23 09:35:16 +0200 |
commit | 2fc464e2162c2b2f7faf7404fa9c35d1cf70aa00 (patch) | |
tree | cf76b124b108cf16c01fa89b0eec113ff6b851ac /drivers/nvme | |
parent | 0d5ee2b2ab4f6776c361bc975c2323bc8b5cf349 (diff) | |
download | linux-2fc464e2162c2b2f7faf7404fa9c35d1cf70aa00.tar.gz linux-2fc464e2162c2b2f7faf7404fa9c35d1cf70aa00.tar.bz2 linux-2fc464e2162c2b2f7faf7404fa9c35d1cf70aa00.zip |
nvmet-rdma: add unlikely check in the fast path
ib_post_send operation should succeed unless something unusual
happened to the ib device.
Signed-off-by: Max Gurtovoy <maxg@mellanox.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/nvme')
-rw-r--r-- | drivers/nvme/target/rdma.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvme/target/rdma.c b/drivers/nvme/target/rdma.c index 2106ae2ec177..4ca09456bbbb 100644 --- a/drivers/nvme/target/rdma.c +++ b/drivers/nvme/target/rdma.c @@ -546,7 +546,7 @@ static void nvmet_rdma_queue_response(struct nvmet_req *req) rsp->send_sge.addr, rsp->send_sge.length, DMA_TO_DEVICE); - if (ib_post_send(cm_id->qp, first_wr, &bad_wr)) { + if (unlikely(ib_post_send(cm_id->qp, first_wr, &bad_wr))) { pr_err("sending cmd response failed\n"); nvmet_rdma_release_rsp(rsp); } |