Subject: [PATCH 03/29] blockdev: do not default cache.no-flush to true

From: Paolo Bonzini <[email-masked]>
Date: Mon, 23 Sep 2013 17:08:01 +0200

RH-Author: Paolo Bonzini <[email-masked]>
Message-id: <[email-masked]>
Patchwork-id: 54491
O-Subject: [RHEL 7.0 qemu-kvm PATCH 1/2] blockdev: do not default cache.no-flush to true
Bugzilla: 1009993
RH-Acked-by: Stefan Hajnoczi <[email-masked]>
RH-Acked-by: Fam Zheng <[email-masked]>
RH-Acked-by: Kevin Wolf <[email-masked]>

That's why all my VMs were so fast lately. :)

This changed in 1.6.0 by mistake in patch 29c4e2b (blockdev: Split up
'cache' option, 2013-07-18).

Cc: [email-masked]
Signed-off-by: Paolo Bonzini <[email-masked]>
Signed-off-by: Stefan Hajnoczi <[email-masked]>
(cherry picked from commit 1df6fa4bc6754a170cf511a78e2e6fef84eb5228)
---
 blockdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Signed-off-by: Miroslav Rezanina <[email-masked]>
---
 blockdev.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/blockdev.c b/blockdev.c
index 8ffed03..073f553 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -459,7 +459,7 @@ static DriveInfo *blockdev_init(QemuOpts *all_opts,
     if (qemu_opt_get_bool(opts, "cache.direct", false)) {
         bdrv_flags |= BDRV_O_NOCACHE;
     }
-    if (qemu_opt_get_bool(opts, "cache.no-flush", true)) {
+    if (qemu_opt_get_bool(opts, "cache.no-flush", false)) {
         bdrv_flags |= BDRV_O_NO_FLUSH;
     }
 
-- 
1.7.1