diff options
author | Sagi Grimberg <sagi@grimberg.me> | 2017-10-11 15:29:10 +0300 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2017-10-18 19:27:54 +0200 |
commit | 60a518863368c7e124cd8411c2481d0938f53e08 (patch) | |
tree | 07e7d109da456641dfbabf6c7d3b0389e04cd5d1 /drivers/nvme | |
parent | 5e1fe61d4170b1f498e20de92c7ce4cd5e40c3c5 (diff) | |
download | talos-obmc-linux-60a518863368c7e124cd8411c2481d0938f53e08.tar.gz talos-obmc-linux-60a518863368c7e124cd8411c2481d0938f53e08.zip |
nvme-rdma: Don't local invalidate if the queue is not live
No chance for the local invalidate to succeed if the queue-pair
is in error state. Most likely the target will do a remote
invalidation of our mr so not a big loss on the test_bit.
Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/nvme')
-rw-r--r-- | drivers/nvme/host/rdma.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvme/host/rdma.c b/drivers/nvme/host/rdma.c index 95837c5317b4..a58dd0c77a29 100644 --- a/drivers/nvme/host/rdma.c +++ b/drivers/nvme/host/rdma.c @@ -1052,7 +1052,7 @@ static void nvme_rdma_unmap_data(struct nvme_rdma_queue *queue, if (!blk_rq_bytes(rq)) return; - if (req->mr->need_inval) { + if (req->mr->need_inval && test_bit(NVME_RDMA_Q_LIVE, &req->queue->flags)) { res = nvme_rdma_inv_rkey(queue, req); if (unlikely(res < 0)) { dev_err(ctrl->ctrl.device, |