[PATCH] nvme-fabrics: fail non-ready command only for NVME_CTRL_DELETING_NOIO
Sagi Grimberg
sagi at grimberg.me
Tue Jul 28 01:42:01 EDT 2020
We allow NVME_CTRL_DELETING to accept I/O.
Signed-off-by: Sagi Grimberg <sagi at grimberg.me>
---
Christoph, another patch we want to fold into
97e9bb2b27bc ("nvme: fix deadlock in disconnect during scan_work and/or ana_work")
thanks...
drivers/nvme/host/fabrics.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/nvme/host/fabrics.c b/drivers/nvme/host/fabrics.c
index 2a6c8190eeb7..4ec4829d6233 100644
--- a/drivers/nvme/host/fabrics.c
+++ b/drivers/nvme/host/fabrics.c
@@ -547,7 +547,7 @@ static struct nvmf_transport_ops *nvmf_lookup_transport(
blk_status_t nvmf_fail_nonready_command(struct nvme_ctrl *ctrl,
struct request *rq)
{
- if (ctrl->state != NVME_CTRL_DELETING &&
+ if (ctrl->state != NVME_CTRL_DELETING_NOIO &&
ctrl->state != NVME_CTRL_DEAD &&
!blk_noretry_request(rq) && !(rq->cmd_flags & REQ_NVME_MPATH))
return BLK_STS_RESOURCE;
--
2.25.1
More information about the Linux-nvme
mailing list