Patchwork [1/1] block: Dont ignore previously set bdrv_flags

login
register
mail settings
Submitter Mohan Kumar M
Date Aug. 14, 2013, 12:26 p.m.
Message ID <1376483201-13466-1-git-send-email-mohan@in.ibm.com>
Download mbox | patch
Permalink /patch/267113/
State New
Headers show

Comments

Mohan Kumar M - Aug. 14, 2013, 12:26 p.m.
From: "M. Mohan Kumar" <mohan@in.ibm.com>

bdrv_flags is set by bdrv_parse_discard_flags(), but later it is reset
to zero.

Signed-off-by: M. Mohan Kumar <mohan@in.ibm.com>
---
 blockdev.c | 1 -
 1 file changed, 1 deletion(-)
Stefan Hajnoczi - Aug. 14, 2013, 1:22 p.m.
On Wed, Aug 14, 2013 at 05:56:41PM +0530, M. Mohan Kumar wrote:
> From: "M. Mohan Kumar" <mohan@in.ibm.com>
> 
> bdrv_flags is set by bdrv_parse_discard_flags(), but later it is reset
> to zero.
> 
> Signed-off-by: M. Mohan Kumar <mohan@in.ibm.com>
> ---
>  blockdev.c | 1 -
>  1 file changed, 1 deletion(-)

Anthony: Please merge this directly into QEMU 1.6, it's a regression
from QEMU 1.5.

Acked-by: Stefan Hajnoczi <stefanha@redhat.com>

Patch

diff --git a/blockdev.c b/blockdev.c
index e174b7d..bc7016a 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -454,7 +454,6 @@  static DriveInfo *blockdev_init(QemuOpts *all_opts,
         }
     }
 
-    bdrv_flags = 0;
     if (qemu_opt_get_bool(opts, "cache.writeback", true)) {
         bdrv_flags |= BDRV_O_CACHE_WB;
     }