* [SPDK] Destroy QP process in nvmf
@ 2019-01-01 14:38 Vikas Gupta
0 siblings, 0 replies; only message in thread
From: Vikas Gupta @ 2019-01-01 14:38 UTC (permalink / raw)
To: spdk
[-- Attachment #1: Type: text/plain, Size: 1516 bytes --]
Hi,
I would like to draw attention in destroy QP process in nvmf that there is
possibility that requests could be processed even after destroy QP in one
of the scenario.
When a disk (hot plug) is removed from the target the related subsystem is
paused and in fly requests are queued as below in nvmf/request.c
*/* Check if the subsystem is paused (if there is a subsystem) */*
* if (qpair->ctrlr) {*
* struct spdk_nvmf_subsystem_poll_group *sgroup =
&qpair->group->sgroups[qpair->ctrlr->subsys->id];*
* if (sgroup->state != SPDK_NVMF_SUBSYSTEM_ACTIVE) {*
* /* The subsystem is not currently active. Queue
this request. */*
* TAILQ_INSERT_TAIL(&sgroup->queued, req, link);*
* return;*
* }*
* } *
By the time system is resumed the QP would have been destroyed and we may
still process the stale QP`s requests with below code in nvmf.c function
spdk_nvmf_poll_group_resume_subsystem().
* /* Release all queued requests */*
* TAILQ_FOREACH_SAFE(req, &sgroup->queued, link, tmp) {*
* TAILQ_REMOVE(&sgroup->queued, req, link);*
* spdk_nvmf_request_exec(req);*
* } *
I think we should remove the stale QP requests from the sgroup`s queue
before we destroy the QP.
Please let me know if my understanding is correct.
Thanks,
Vikas
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2019-01-01 14:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-01-01 14:38 [SPDK] Destroy QP process in nvmf Vikas Gupta
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox