summaryrefslogtreecommitdiff
path: root/include/block/block.h
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2015-04-07 16:55:00 +0200
committerKevin Wolf <kwolf@redhat.com>2015-06-12 16:58:07 +0200
commit54861b9280e95dd16c062b26a9d0adfe3608c63c (patch)
treee1d1ff1187697f8ffb22cb92dfcd1138d697b00d /include/block/block.h
parenta646836784a0fc50fee6f9a0d3fb968289714128 (diff)
downloadqemu-54861b9280e95dd16c062b26a9d0adfe3608c63c.tar.gz
block: Use macro for cache option names
Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Jeff Cody <jcody@redhat.com> Reviewed-by: Alberto Garcia <berto@igalia.com>
Diffstat (limited to 'include/block/block.h')
-rw-r--r--include/block/block.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/block/block.h b/include/block/block.h
index f7680b6e68..5f3c2de59c 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -90,6 +90,14 @@ typedef struct HDGeometry {
#define BDRV_O_CACHE_MASK (BDRV_O_NOCACHE | BDRV_O_CACHE_WB | BDRV_O_NO_FLUSH)
+
+/* Option names of options parsed by the block layer */
+
+#define BDRV_OPT_CACHE_WB "cache.writeback"
+#define BDRV_OPT_CACHE_DIRECT "cache.direct"
+#define BDRV_OPT_CACHE_NO_FLUSH "cache.no-flush"
+
+
#define BDRV_SECTOR_BITS 9
#define BDRV_SECTOR_SIZE (1ULL << BDRV_SECTOR_BITS)
#define BDRV_SECTOR_MASK ~(BDRV_SECTOR_SIZE - 1)