nvmet-rdma: Add unlikely for response allocated check
authorIsrael Rukshin <israelr@mellanox.com>
Mon, 19 Nov 2018 10:58:51 +0000 (10:58 +0000)
committerJens Axboe <axboe@kernel.dk>
Sat, 8 Dec 2018 05:26:58 +0000 (22:26 -0700)
Signed-off-by: Israel Rukshin <israelr@mellanox.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/nvme/target/rdma.c

index 3f7971d3706d90d5fbf382072ed8d2da2ac6e8b6..932242e27b03ea173295f2922ae3b2efcccdea2a 100644 (file)
@@ -196,7 +196,7 @@ nvmet_rdma_put_rsp(struct nvmet_rdma_rsp *rsp)
 {
        unsigned long flags;
 
-       if (rsp->allocated) {
+       if (unlikely(rsp->allocated)) {
                kfree(rsp);
                return;
        }