nvme_fc: stop queues on error detection
Subsystems (2)
PATCH 1/1 nvme_fc: stop queues on error detection
From: James Smart <[email protected]>
Per the recommendation by Sagi on:
http://lists.infradead.org/pipermail/linux-nvme/2017-April/009261.html
Rather than waiting for reset work thread to stop queues and abort the ios, immediately stop the queues on error detection. Reset thread will restop the queues (as it's called on other paths), but it does not appear to have a side effect.
--- drivers/nvme/host/fc.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/nvme/host/fc.c +4 -0
@@ -1751,6 +1751,10 @@ nvme_fc_error_recovery(struct nvme_fc_ctrl *ctrl, char *errmsg)dev_info (ctrl->ctrl.device,"NVME-FC{%d}: resetting controller\n" , ctrl->cnum); +/* stop the queues on error, cleanup is in reset thread */ +if (ctrl->queue_count >1 ) +nvme_stop_queues (&ctrl->ctrl); +if (!nvme_change_ctrl_state (&ctrl->ctrl,NVME_CTRL_RECONNECTING )) {dev_err (ctrl->ctrl.device, "NVME-FC{%d}: error_recovery: Couldn't change state "
Signature · 1 line
2.9.3
PATCH 1/1 nvme_fc: stop queues on error detection
Quoted 5 lines · On 04/26/2017 12:32 AM, [email protected] wrote:
From: James Smart <jsmart2021 at gmail.com>
Per the recommendation by Sagi on:
http://lists.infradead.org/pipermail/linux-nvme/2017-April/009261.html
Quoted 7 lines
Rather than waiting for reset work thread to stop queues and abort the ios, immediately stop the queues on error detection. Reset thread will restop the queues (as it's called on other paths), but it does not appear to have a side effect.
Signed-off-by James Smart <james.smart at broadcom.com>---
Looks good,
Reviewed-by: Johannes Thumshirn <jthumshirn at suse.de>
Signature · 6 lines
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
Christoph Hellwig
AppliedPATCH 1/1 nvme_fc: stop queues on error detection
In reply to [email protected]Thanks,
applied to nvme-4.12.