summaryrefslogtreecommitdiffstats
path: root/include/block/block.h
diff options
context:
space:
mode:
authorAndrey Shinkevich2019-03-07 14:33:58 +0100
committerKevin Wolf2019-03-08 12:26:45 +0100
commit9ac404c5233f3033435ab250d30ea9f776188a01 (patch)
treee1e0d6369a04c920bb6b1d3aa993fbaf5b972cdf /include/block/block.h
parentiotests: open notrun files in text mode (diff)
downloadqemu-9ac404c5233f3033435ab250d30ea9f776188a01.tar.gz
qemu-9ac404c5233f3033435ab250d30ea9f776188a01.tar.xz
qemu-9ac404c5233f3033435ab250d30ea9f776188a01.zip
block: iterate_format with account of whitelisting
bdrv_iterate_format (which is currently only used for printing out the formats supported by the block layer) doesn't take format whitelisting into account. This creates a problem for tests: they enumerate supported formats to decide which tests to enable, but then discover that QEMU doesn't let them actually use some of those formats. To avoid that, exclude formats that are not whitelisted from enumeration, if whitelisting is in use. Since we have separate whitelists for r/w and r/o, take this a parameter to bdrv_iterate_format, and print two lists of supported formats (r/w and r/o) in main qemu. Signed-off-by: Roman Kagan <rkagan@virtuozzo.com> Signed-off-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'include/block/block.h')
-rw-r--r--include/block/block.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/block/block.h b/include/block/block.h
index 5b5cf868df..6a758a76f8 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -472,7 +472,7 @@ void bdrv_next_cleanup(BdrvNextIterator *it);
BlockDriverState *bdrv_next_monitor_owned(BlockDriverState *bs);
bool bdrv_is_encrypted(BlockDriverState *bs);
void bdrv_iterate_format(void (*it)(void *opaque, const char *name),
- void *opaque);
+ void *opaque, bool read_only);
const char *bdrv_get_node_name(const BlockDriverState *bs);
const char *bdrv_get_device_name(const BlockDriverState *bs);
const char *bdrv_get_device_or_node_name(const BlockDriverState *bs);