All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Christoph Hellwig <hch@infradead.org>, Meelis Roos <mroos@linux.ee>
Cc: linux-scsi@vger.kernel.org
Subject: Re: blk-mq problem on proliant DL380 G3 (cciss)
Date: Sun, 02 Nov 2014 18:23:51 -0700	[thread overview]
Message-ID: <5456D927.7040403@kernel.dk> (raw)
In-Reply-To: <20141030174536.GA27799@infradead.org>

On 2014-10-30 11:45, Christoph Hellwig wrote:
> On Thu, Oct 30, 2014 at 07:32:52PM +0200, Meelis Roos wrote:
>>> can you try the patch below?  It's a hack and not a proper fix, but it
>>> addresses what seems to be your culprit, given that it is the only
>>> place allocating a request from the error handler.
>>
>> Applied it on top of 3.18-rc2, booted with scsi_mod.use_blk_mq=1 and it
>> booted up fine.
>
> Jens,
>
> any idea what we could do here?  We want to lock the door again ASAP
> after potentially resetting the device state as far as I can read
> the code (the commit message for it is utterly meaningless).
>
> Right now the code allocates the request from the scsi EH thread, which
> already is dangerous but mostly works for the !blk-mq case, but with the
> strict only allocate a request if a tag is available policy this breaks
> down if we still have BLOCK_PC requests that have references on them
> blocking another request queued (ATA cdroms tend to have a queue depth
> of 1).
>
> Given that this always was best effort anyway we might want to move it
> to a separate workqueue to not block EH?

So what we usually do for tagged devices that need some command for 
error handling etc, is to have one tag reserved. The lock/unlock should 
probably be using a reserved request, given how it is invoked as error 
handling. Right now we don't reserve a tag for untagged things like PATA 
cdrom, but we could, since they don't care about the tag anyway. And if 
we had that and reserved grab in the scsi_eh_lock_door(), it should just 
work.

-- 
Jens Axboe


  reply	other threads:[~2014-11-03  1:23 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-29 10:47 blk-mq problem on proliant DL380 G3 (cciss) Meelis Roos
2014-10-29 11:46 ` Meelis Roos
2014-10-29 15:08   ` Jens Axboe
2014-10-29 15:38     ` Meelis Roos
2014-10-29 22:50       ` Elliott, Robert (Server Storage)
2014-10-29 18:38     ` Christoph Hellwig
2014-10-29 20:06       ` Meelis Roos
2014-10-29 20:13         ` Jens Axboe
2014-10-30  5:46           ` Meelis Roos
2014-10-30 11:18           ` Meelis Roos
2014-10-30 15:19             ` Christoph Hellwig
2014-10-30 17:32               ` Meelis Roos
2014-10-30 17:45                 ` Christoph Hellwig
2014-11-03  1:23                   ` Jens Axboe [this message]
2014-11-03 10:08 ` Christoph Hellwig
2014-11-03 13:05   ` Meelis Roos

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=5456D927.7040403@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=hch@infradead.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mroos@linux.ee \
    /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 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.