From: axboe@kernel.dk (Jens Axboe)
Subject: [PATCH] NVMe: Re-introduce nvmeq->q_suspended
Date: Fri, 21 Nov 2014 18:11:32 -0700 [thread overview]
Message-ID: <546FE2C4.5060905@kernel.dk> (raw)
In-Reply-To: <alpine.LNX.2.00.1411220053400.4225@localhost.lm.intel.com>
On 11/21/2014 06:07 PM, Keith Busch wrote:
> On Fri, 21 Nov 2014, Sam Bradshaw wrote:
>> At some point in the blk-mq transition, q_suspended was removed. This
>> patch adds it back to address two failure modes, both illustrated in
>> the attached snippet. First, it protects the ioctl path from
>> inadvertently dereferencing invalid nvme_queue data structures during
>> device shutdown/reset. Second, it protects against a double
>> free_irq() if the shutdown/reset/resume sequence doesn't recover a
>> flaky controller.
>
> I could have sworn there was a better way to suspend at the
> request_queue level with blk-mq so we don't need this in the driver. The
> blk_start/stop_queue is close, but doesn't work in the ioctl path. Maybe
> I'm thinking blk-mq freeze, but that's not exported for drivers.
The freeze stuff should work. I've got a prelim patch that allows
attach/detach of the namespace/block parts, the first prep patch is
exporting the freeze bits.
--
Jens Axboe
next prev parent reply other threads:[~2014-11-22 1:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-22 0:24 [PATCH] NVMe: Re-introduce nvmeq->q_suspended Sam Bradshaw
2014-11-22 1:07 ` Keith Busch
2014-11-22 1:11 ` Jens Axboe [this message]
2014-12-09 22:08 ` Sam Bradshaw (sbradshaw)
2014-12-12 16:02 ` Jens Axboe
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=546FE2C4.5060905@kernel.dk \
--to=axboe@kernel.dk \
/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