From: Jens Axboe <axboe@kernel.dk>
To: David Hildenbrand <dahi@linux.vnet.ibm.com>,
Ming Lei <tom.leiming@gmail.com>
Cc: KVM list <kvm@vger.kernel.org>,
"Michael S. Tsirkin" <mst@redhat.com>,
"linux-kernel@vger.kernel.org >> Linux Kernel Mailing List"
<linux-kernel@vger.kernel.org>,
Virtualization List <virtualization@lists.linux-foundation.org>,
Christian Borntraeger <borntraeger@de.ibm.com>
Subject: Re: blk-mq crash under KVM in multiqueue block code (with virtio-blk and ext4)
Date: Wed, 17 Sep 2014 14:16:25 -0600 [thread overview]
Message-ID: <5419EC19.9050100@kernel.dk> (raw)
In-Reply-To: <20140917210954.6e622fb5@thinkpad-w530>
On 09/17/2014 01:09 PM, David Hildenbrand wrote:
>>> 0. That should already be sufficient to hinder blk_mq_tag_to_rq and the calling
>>> method to do the wrong thing.
>>
>> Yes, clearing rq->cmd_flags should be enough.
>>
>> And looks better to move rq initialization to __blk_mq_free_request()
>> too, otherwise timeout still may see old cmd_flags and rq->q before
>> rq's new initialization.
>
> Yes, __blk_mq_free_request() should also reset at least rq->cmd_flags, and I
> think we can remove the initialization from __blk_mq_alloc_request().
And then we come full circle, that's how the code originally started out
(and it is the saner way to do things). So yes, I'd greatly applaud that.
--
Jens Axboe
WARNING: multiple messages have this Message-ID (diff)
From: Jens Axboe <axboe@kernel.dk>
To: David Hildenbrand <dahi@linux.vnet.ibm.com>,
Ming Lei <tom.leiming@gmail.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>,
rusty Russell <rusty@rustcorp.com.au>,
"Michael S. Tsirkin" <mst@redhat.com>,
KVM list <kvm@vger.kernel.org>,
Virtualization List <virtualization@lists.linux-foundation.org>,
"linux-kernel@vger.kernel.org >> Linux Kernel Mailing List"
<linux-kernel@vger.kernel.org>
Subject: Re: blk-mq crash under KVM in multiqueue block code (with virtio-blk and ext4)
Date: Wed, 17 Sep 2014 14:16:25 -0600 [thread overview]
Message-ID: <5419EC19.9050100@kernel.dk> (raw)
In-Reply-To: <20140917210954.6e622fb5@thinkpad-w530>
On 09/17/2014 01:09 PM, David Hildenbrand wrote:
>>> 0. That should already be sufficient to hinder blk_mq_tag_to_rq and the calling
>>> method to do the wrong thing.
>>
>> Yes, clearing rq->cmd_flags should be enough.
>>
>> And looks better to move rq initialization to __blk_mq_free_request()
>> too, otherwise timeout still may see old cmd_flags and rq->q before
>> rq's new initialization.
>
> Yes, __blk_mq_free_request() should also reset at least rq->cmd_flags, and I
> think we can remove the initialization from __blk_mq_alloc_request().
And then we come full circle, that's how the code originally started out
(and it is the saner way to do things). So yes, I'd greatly applaud that.
--
Jens Axboe
next prev parent reply other threads:[~2014-09-17 20:16 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-11 10:26 blk-mq crash under KVM in multiqueue block code (with virtio-blk and ext4) Christian Borntraeger
2014-09-11 10:26 ` Christian Borntraeger
2014-09-12 10:56 ` Christian Borntraeger
2014-09-12 10:56 ` Christian Borntraeger
2014-09-12 11:54 ` Ming Lei
2014-09-12 11:54 ` Ming Lei
2014-09-12 20:09 ` Christian Borntraeger
2014-09-12 20:09 ` Christian Borntraeger
2014-09-17 7:59 ` Christian Borntraeger
2014-09-17 7:59 ` Christian Borntraeger
2014-09-17 10:01 ` Ming Lei
2014-09-17 10:01 ` Ming Lei
2014-09-17 12:00 ` David Hildenbrand
2014-09-17 13:52 ` Ming Lei
2014-09-17 13:52 ` Ming Lei
2014-09-17 13:52 ` Ming Lei
2014-09-17 14:11 ` David Hildenbrand
2014-09-17 14:11 ` David Hildenbrand
2014-09-17 14:22 ` Jens Axboe
2014-09-17 14:22 ` Jens Axboe
2014-09-17 15:24 ` Ming Lei
2014-09-17 15:24 ` Ming Lei
2014-09-17 19:09 ` David Hildenbrand
2014-09-17 19:09 ` David Hildenbrand
2014-09-17 20:16 ` Jens Axboe [this message]
2014-09-17 20:16 ` Jens Axboe
2014-09-18 2:13 ` Ming Lei
2014-09-18 2:13 ` Ming Lei
2014-09-17 12:00 ` David Hildenbrand
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=5419EC19.9050100@kernel.dk \
--to=axboe@kernel.dk \
--cc=borntraeger@de.ibm.com \
--cc=dahi@linux.vnet.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=tom.leiming@gmail.com \
--cc=virtualization@lists.linux-foundation.org \
/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.