From: "Blue Swirl" <blauwirbel@gmail.com>
To: Kevin Wolf <kwolf@suse.de>
Cc: Laurent Vivier <Laurent.Vivier@bull.net>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] Align file accesses with cache=off (O_DIRECT)
Date: Tue, 6 May 2008 19:42:09 +0300 [thread overview]
Message-ID: <f43fc5580805060942p1d1edd18j30b5652a43aca656@mail.gmail.com> (raw)
In-Reply-To: <48201A71.3040405@suse.de>
On 5/6/08, Kevin Wolf <kwolf@suse.de> wrote:
> Kevin Wolf schrieb:
>
>
> > Am Donnerstag, 1. Mai 2008 16:35:51 schrieb Blue Swirl:
> >
> > > On 5/1/08, Kevin Wolf <mail@kevin-wolf.de> wrote:
> > >
> > > > Am Mittwoch, 30. April 2008 16:30:27 schrieb Blue Swirl:
> > > >
> > > > > Maybe the alignment could be handled like AIO and synchronous IO
> > > > >
> > > > >
> > > > > emulation layers are added in bdrv_register, but at open stage?
> > > >
> > > > You mean to preserve the original pread if the file is opened without
> > > > O_DIRECT and replace it by the emulation function only if O_DIRECT is
> > > > really used?
> > > >
> > > Right.
> > >
> > > Maybe it's slightly faster that way and it would be closer to how
> > > other block emulations are handled. It's just an idea.
> > >
> >
> > Maybe I'm missing something but AFAIK this pread pointer exists once for
> each block driver, i.e. every raw image uses the original pread or every raw
> image uses the emulating one. The difference between the O_DIRECT case and
> the AIO/sync emulation is that AIO/sync is the same for all devices of one
> driver while O_DIRECT can differ between images of the same driver.
> >
> > So you would need to have one common pread which in turn calls a function
> pointer stored in the BlockDriverState. I doubt that this is much cheaper
> than an if in pread. And it wouldn't get too close to other emulations
> anyway because of the driver/device difference.
> >
>
> Should I change the patch now (even if I think it doesn't help anything) or
> will you apply the patch as it is? It is quite frustrating to get no answer
> at all.
Well, the patch looks OK. But I try to test the patches before I
commit and for this I don't know how. Could you give some example test
cases?
next prev parent reply other threads:[~2008-05-06 16:42 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-17 13:31 [Qemu-devel] [PATCH] Align file accesses with cache=off (O_DIRECT) Kevin Wolf
2008-04-28 15:34 ` Kevin Wolf
2008-04-29 9:01 ` Laurent Vivier
2008-04-29 14:49 ` Kevin Wolf
2008-04-29 15:48 ` Laurent Vivier
2008-04-29 16:21 ` Kevin Wolf
2008-04-29 16:48 ` Laurent Vivier
2008-04-30 9:21 ` Kevin Wolf
2008-04-30 9:59 ` Laurent Vivier
2008-04-30 12:08 ` Kevin Wolf
2008-04-30 14:30 ` Blue Swirl
2008-04-30 21:05 ` Kevin Wolf
2008-05-01 14:35 ` Blue Swirl
2008-05-01 17:55 ` Kevin Wolf
2008-05-06 8:44 ` Kevin Wolf
2008-05-06 9:02 ` Laurent Vivier
2008-05-06 16:42 ` Blue Swirl [this message]
2008-05-06 16:56 ` Kevin Wolf
2008-05-06 17:23 ` Blue Swirl
2008-04-30 0:05 ` Jamie Lokier
2008-04-30 0:02 ` Jamie Lokier
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=f43fc5580805060942p1d1edd18j30b5652a43aca656@mail.gmail.com \
--to=blauwirbel@gmail.com \
--cc=Laurent.Vivier@bull.net \
--cc=kwolf@suse.de \
--cc=qemu-devel@nongnu.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).