* [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting
@ 2017-10-11 9:49 Sagi Grimberg
2017-10-11 10:28 ` Johannes Thumshirn
2017-10-16 12:46 ` Christoph Hellwig
0 siblings, 2 replies; 3+ messages in thread
From: Sagi Grimberg @ 2017-10-11 9:49 UTC (permalink / raw)
If the controller is deleting (in case the user decided to delete
it), we have no point to continue reset sequence.
Signed-off-by: Sagi Grimberg <sagi at grimberg.me>
---
drivers/nvme/host/rdma.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/nvme/host/rdma.c b/drivers/nvme/host/rdma.c
index 039f38cb6987..cf2ac5d893d5 100644
--- a/drivers/nvme/host/rdma.c
+++ b/drivers/nvme/host/rdma.c
@@ -1821,7 +1821,11 @@ static void nvme_rdma_reset_ctrl_work(struct work_struct *work)
}
changed = nvme_change_ctrl_state(&ctrl->ctrl, NVME_CTRL_LIVE);
- WARN_ON_ONCE(!changed);
+ if (!changed) {
+ /* state change failure is ok if we're in DELETING state */
+ WARN_ON_ONCE(ctrl->ctrl.state != NVME_CTRL_DELETING);
+ return;
+ }
nvme_start_ctrl(&ctrl->ctrl);
--
2.7.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting
2017-10-11 9:49 [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting Sagi Grimberg
@ 2017-10-11 10:28 ` Johannes Thumshirn
2017-10-16 12:46 ` Christoph Hellwig
1 sibling, 0 replies; 3+ messages in thread
From: Johannes Thumshirn @ 2017-10-11 10:28 UTC (permalink / raw)
Looks good,
Reviewed-by: Johannes Thumshirn <jthumshirn at suse.de>
--
Johannes Thumshirn Storage
jthumshirn at suse.de +49 911 74053 689
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 N?rnberg
GF: Felix Imend?rffer, Jane Smithard, Graham Norton
HRB 21284 (AG N?rnberg)
Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting
2017-10-11 9:49 [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting Sagi Grimberg
2017-10-11 10:28 ` Johannes Thumshirn
@ 2017-10-16 12:46 ` Christoph Hellwig
1 sibling, 0 replies; 3+ messages in thread
From: Christoph Hellwig @ 2017-10-16 12:46 UTC (permalink / raw)
On Wed, Oct 11, 2017@12:49:51PM +0300, Sagi Grimberg wrote:
> If the controller is deleting (in case the user decided to delete
> it), we have no point to continue reset sequence.
>
> Signed-off-by: Sagi Grimberg <sagi at grimberg.me>
Looks good and mirrors what we do in reconnect.
I'll apply it to nvme-4.14.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-10-16 12:46 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-11 9:49 [PATCH 4.14-rc] nvme-rdma: stop controller reset if the controller is deleting Sagi Grimberg
2017-10-11 10:28 ` Johannes Thumshirn
2017-10-16 12:46 ` Christoph Hellwig
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.