lib/nvme: set qpairs to destroy when ctrlr is removed.
This is the onlyreasonable thing to do. Plus we need to be in the destroying or disconnecting state to avoid an infinite loop when aborting requests. Signed-off-by: Seth Howell <seth.howell@intel.com> Change-Id: I38462a01f0455c3d6496434626f6f2f4663bf508 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1857 Community-CI: Mellanox Build Bot Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
7defb70d3a
commit
b2a93a320d
@ -458,6 +458,7 @@ spdk_nvme_qpair_process_completions(struct spdk_nvme_qpair *qpair, uint32_t max_
|
||||
|
||||
if (spdk_unlikely(qpair->ctrlr->is_failed)) {
|
||||
if (qpair->ctrlr->is_removed) {
|
||||
nvme_qpair_set_state(qpair, NVME_QPAIR_DESTROYING);
|
||||
nvme_qpair_abort_reqs(qpair, 1 /* Do not retry */);
|
||||
}
|
||||
return -ENXIO;
|
||||
|
Loading…
Reference in New Issue
Block a user