From: Asias He <asias@redhat.com>
To: Rusty Russell <rusty@rustcorp.com.au>
Cc: kvm@vger.kernel.org, "Michael S. Tsirkin" <mst@redhat.com>,
linux-kernel@vger.kernel.org,
virtualization@lists.linux-foundation.org,
Paolo Bonzini <pbonzini@redhat.com>,
Christoph Hellwig <hch@lst.de>
Subject: Re: [PATCH V3 3/3] virtio-blk: Add bio-based IO path for virtio-blk
Date: Sat, 28 Jul 2012 10:38:41 +0800 [thread overview]
Message-ID: <501350B1.7080908@redhat.com> (raw)
In-Reply-To: <87d33initv.fsf@rustcorp.com.au>
On 07/27/2012 08:33 AM, Rusty Russell wrote:
> On Fri, 13 Jul 2012 16:38:51 +0800, Asias He <asias@redhat.com> wrote:
>> Add 'virtio_blk.use_bio=1' to kernel cmdline or 'modprobe virtio_blk
>> use_bio=1' to enable ->make_request_fn() based I/O path.
>
> This patch conflicts with Paolo's Bonzini's 'virtio-blk: allow toggling
> host cache between writeback and writethrough' which is also queued (see
> linux-next).
Rebased against Paolo's patch in V4.
> I'm not sure what the correct behavior for bio & cacheflush is, if any.
REQ_FLUSH is not supported in the bio path.
> But as to the patch itself: it's a hack.
>
> 1) Leaving the guest's admin to turn on the switch is a terrible choice.
> 2) The block layer should stop merging and sorting when a device is
> fast, not the driver.
> 3) I pointed out that slow disks have low IOPS, so why is this
> conditional? Sure, more guest exits, but it's still a small number
> for a slow device.
> 4) The only case where we want merging is on a slow device when the host
> isn't doing it.
>
> Now, despite this, I'm prepared to commit it. But in my mind it's a
> hack: we should aim for use_bio to be based on a feature bit fed from
> the host, and use the module parameter only if we want to override it.
OK. A feature bit from host sound like a choice but a switch is also
needed on host side. And for other OS, e.g. Windows, the bio thing does
not apply at all.
Anyway, I have to admit that adding a module parameter here is not the
best choice. Let's think more.
--
Asias
next prev parent reply other threads:[~2012-07-28 2:38 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-13 8:38 [PATCH V3 0/3] Improve virtio-blk performance Asias He
2012-07-13 8:38 ` [PATCH V3 1/3] block: Introduce __blk_segment_map_sg() helper Asias He
2012-07-13 8:38 ` [PATCH V3 2/3] block: Add blk_bio_map_sg() helper Asias He
2012-07-13 8:38 ` [PATCH V3 3/3] virtio-blk: Add bio-based IO path for virtio-blk Asias He
2012-07-27 0:33 ` Rusty Russell
2012-07-28 2:38 ` Asias He [this message]
2012-07-28 6:42 ` Paolo Bonzini
2012-07-30 4:43 ` Asias He
2012-07-30 7:31 ` Paolo Bonzini
2012-07-30 13:44 ` Christoph Hellwig
2012-08-02 6:28 ` Asias He
2012-07-30 13:43 ` Christoph Hellwig
2012-07-31 8:43 ` Asias He
2012-07-29 12:59 ` Michael S. Tsirkin
2012-07-30 0:26 ` Asias He
2012-07-27 6:29 ` Rusty Russell
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=501350B1.7080908@redhat.com \
--to=asias@redhat.com \
--cc=hch@lst.de \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=rusty@rustcorp.com.au \
--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 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).