From: Sagi Grimberg Date: Thu, 4 May 2017 10:33:12 +0000 (+0300) Subject: nvme: Don't allow to reset a reconnecting controller X-Git-Tag: v4.14-rc1~509^2~67^2~30 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c58bd1bf4d46a020b7a1aa0710bca8191d789caa;p=platform%2Fkernel%2Flinux-rpi.git nvme: Don't allow to reset a reconnecting controller The reset operation is guaranteed to fail for all scenarios but the esoteric case where in the last reconnect attempt concurrent with the reset we happen to successfully reconnect. We just deny initiating a reset if we are reconnecting. Signed-off-by: Sagi Grimberg Signed-off-by: Christoph Hellwig --- diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c index 767bcc6..6d53094 100644 --- a/drivers/nvme/host/core.c +++ b/drivers/nvme/host/core.c @@ -157,7 +157,6 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl, switch (old_state) { case NVME_CTRL_NEW: case NVME_CTRL_LIVE: - case NVME_CTRL_RECONNECTING: changed = true; /* FALLTHRU */ default: