From: Stefan Hajnoczi <stefanha@gmail.com>
To: lihuiba <magazine.lihuiba@163.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] when to bdrv_co_flush()?
Date: Thu, 13 Nov 2014 11:36:23 +0000 [thread overview]
Message-ID: <20141113113623.GP7462@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <7bbecfc7.afc2.1499801f415.Coremail.magazine.lihuiba@163.com>
[-- Attachment #1: Type: text/plain, Size: 849 bytes --]
On Mon, Nov 10, 2014 at 12:41:45PM +0800, lihuiba wrote:
> bdrv_co_flush() will flush all cached data to persistent storage, and I'm
> wondering whether guest sync() will eventually trigger bdrv_co_flush() be
> called.
virtio-blk and other emulated storage controllers use bdrv_aio_flush()
to implement disk write cache flush commands.
> Intuitively, guest sync() should trigger bdrv_co_flush() in qemu. But simple
>
> grep gave me a negative answer. So I'm wondering why it's not like what I
>
> suspected.
A correctly configured guest will send cache flush commands, and a
correctly configured QEMU will honor them.
If want help finding the answer, please provide details:
1. Your QEMU command-line
2. Your guest OS version and file system mount options
3. Why you believe bdrv_co_flush() is not being called
Stefan
[-- Attachment #2: Type: application/pgp-signature, Size: 473 bytes --]
next prev parent reply other threads:[~2014-11-13 11:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-10 4:41 [Qemu-devel] when to bdrv_co_flush()? lihuiba
2014-11-13 11:36 ` Stefan Hajnoczi [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-11-10 4:37 lihuiba
2014-11-10 2:35 lihuiba
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=20141113113623.GP7462@stefanha-thinkpad.redhat.com \
--to=stefanha@gmail.com \
--cc=magazine.lihuiba@163.com \
--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).