nvme_fc: avoid workqueue flush stalls
Subsystems (2)
PATCH 1/1 nvme_fc: avoid workqueue flush stalls
There's no need to wait for the full nvme_wq, which is now shared, to flush. flush only the delete_work item.
--- drivers/nvme/host/fc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/nvme/host/fc.c +1 -1
@@ -2846,7 +2846,7 @@ nvme_fc_del_nvme_ctrl(struct nvme_ctrl *nctrl) ret =__nvme_fc_del_ctrl (ctrl);if (!ret) -flush_workqueue (nvme_wq); +flush_work (&ctrl->delete_work);nvme_put_ctrl (&ctrl->ctrl);
Signature · 1 line
2.13.1
Sagi Grimberg
maintainerPATCH 1/1 nvme_fc: avoid workqueue flush stalls
Quoted 3 lines
There's no need to wait for the full
nvme_wq, which is now shared, to flush. flush only thedelete_workitem.
The patch looks correct, but can you explain what stalled that this patch fixes?
PATCH 1/1 nvme_fc: avoid workqueue flush stalls
Quoted 6 lines · Sagi Grimberg
Quoted 3 lines
There's no need to wait for the full
nvme_wq, which is now shared, to flush. flush only thedelete_workitem.The patch looks correct, but can you explain what stalled that this patch fixes?
I don't have an explicit failure case. While reviewing the code for the other stall issue with fatal_err_work, I realized that this flush is now waiting on a work queue shared by everything nvmf.? It used to be solely a nvme-fc transport workqueue. There's no need for waiting on anything more than the delete work item. And having it raise in scope of the nvmf thread perhaps makes it wait for a lot of other unnecessary things - slowing it down.
If you're ok with it - can you Ack/Review it ?
-- james
Sagi Grimberg
maintainerPATCH 1/1 nvme_fc: avoid workqueue flush stalls
Quoted 15 lines
Quoted 6 lines
Quoted 3 lines
There's no need to wait for the full
nvme_wq, which is now shared, to flush. flush only thedelete_workitem.The patch looks correct, but can you explain what stalled that this patch fixes?
I don't have an explicit failure case. While reviewing the code for the other stall issue with
fatal_err_work, I realized that this flush is now waiting on a work queue shared by everything nvmf.? It used to be solely a nvme-fc transport workqueue. There's no need for waiting on anything more than the delete work item. And having it raise in scope of the nvmf thread perhaps makes it wait for a lot of other unnecessary things - slowing it down.
Quoted 1 line
If you're ok with it - can you Ack/Review it ?