summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2016-03-18 17:46:45 +0100
committerKevin Wolf <kwolf@redhat.com>2016-03-30 12:16:03 +0200
commit61de4c680846167e01d7ba42bf787f8d1d80bf5e (patch)
treeec4a6353a6f747b6201e5411ad77382ad39f2437 /include
parent53e8ae010071637b4317402e2ece9e4dbb329c50 (diff)
downloadqemu-61de4c680846167e01d7ba42bf787f8d1d80bf5e.tar.gz
qemu-61de4c680846167e01d7ba42bf787f8d1d80bf5e.tar.bz2
qemu-61de4c680846167e01d7ba42bf787f8d1d80bf5e.zip
block: Remove BDRV_O_CACHE_WB
The previous patches have successively made blk->enable_write_cache the true source for the information whether a writethrough mode must be implemented. The corresponding BDRV_O_CACHE_WB is only useless baggage we're carrying around, so now's the time to remove it. At the same time, we remove the 'cache.writeback' option parsing on the BDS level as the only effect was setting the BDRV_O_CACHE_WB flag. This change requires test cases that explicitly enabled the option to drop it. Other than that and the change of the error message when writethrough is enabled on the BDS level (from "Can't set writethrough mode" to "doesn't support the option"), there should be no change in behaviour. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/block/block.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/include/block/block.h b/include/block/block.h
index 738eeb6ffa..7bacd556b8 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -82,7 +82,6 @@ typedef struct HDGeometry {
#define BDRV_O_SNAPSHOT 0x0008 /* open the file read only and save writes in a snapshot */
#define BDRV_O_TEMPORARY 0x0010 /* delete the file after use */
#define BDRV_O_NOCACHE 0x0020 /* do not use the host page cache */
-#define BDRV_O_CACHE_WB 0x0040 /* use write-back caching */
#define BDRV_O_NATIVE_AIO 0x0080 /* use native AIO instead of the thread pool */
#define BDRV_O_NO_BACKING 0x0100 /* don't open the backing file */
#define BDRV_O_NO_FLUSH 0x0200 /* disable flushing on this disk */
@@ -96,7 +95,7 @@ typedef struct HDGeometry {
ignoring the format layer */
#define BDRV_O_NO_IO 0x10000 /* don't initialize for I/O */
-#define BDRV_O_CACHE_MASK (BDRV_O_NOCACHE | BDRV_O_CACHE_WB | BDRV_O_NO_FLUSH)
+#define BDRV_O_CACHE_MASK (BDRV_O_NOCACHE | BDRV_O_NO_FLUSH)
/* Option names of options parsed by the block layer */