From: keith.busch@linux.intel.com (Keith Busch)
Subject: [PATCH] nvme/pci: Sync controller reset for AER slot_reset
Date: Thu, 10 May 2018 13:14:17 -0600 [thread overview]
Message-ID: <20180510191417.GA4787@localhost.localdomain> (raw)
In-Reply-To: <93d528ce-043a-5118-02b3-986d151b37cf@gmail.com>
On Thu, May 10, 2018@01:56:56PM -0500, Alex G. wrote:
> > @@ -2681,8 +2681,15 @@ static pci_ers_result_t nvme_slot_reset(struct pci_dev *pdev)
> >
> > dev_info(dev->ctrl.device, "restart after slot reset\n");
> > pci_restore_state(pdev);
> > - nvme_reset_ctrl(&dev->ctrl);
> > - return PCI_ERS_RESULT_RECOVERED;
> > + nvme_reset_ctrl_sync(&dev->ctrl);
>
> This does wonders when nvme_reset_ctrl_sync() returns in a timely
> manner. I was also able to get the nvme drive in a state where
> nvme_reset_ctrl_sync() does not return. Then we end up with the device
> lock in report_slot_reset, which, as you may imagine, is not a great thing.
It never returns? That shouldn't happen. There are cases where it may take
a very long time, depending on what the controller reports in CAP.TO. The
only other case it may stall is if the controller never responds to the
initialization admin commands, but that should delay by 60 seconds under
default parameters.
next prev parent reply other threads:[~2018-05-10 19:14 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-10 16:01 [PATCH] nvme/pci: Sync controller reset for AER slot_reset Keith Busch
2018-05-10 18:56 ` Alex G.
2018-05-10 19:14 ` Keith Busch [this message]
2018-05-10 19:20 ` Alex G.
2018-05-11 14:18 ` Alex G.
2018-05-12 9:27 ` Ming Lei
2018-05-11 6:38 ` Christoph Hellwig
2018-05-11 20:54 ` Martin K. Petersen
2018-05-11 21:09 ` Keith Busch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180510191417.GA4787@localhost.localdomain \
--to=keith.busch@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).