diff --git a/blockdev.c b/blockdev.c index fc8794862fed740934fec108c2eacebeb392994b..e5b5eb46e2e98ebedb835f3940cb73b65c104667 100644 --- a/blockdev.c +++ b/blockdev.c @@ -590,6 +590,7 @@ static BlockBackend *blockdev_init(const char *file, QDict *bs_opts, qdict_set_default_str(bs_opts, BDRV_OPT_CACHE_NO_FLUSH, "off"); qdict_set_default_str(bs_opts, BDRV_OPT_READ_ONLY, read_only ? "on" : "off"); + qdict_set_default_str(bs_opts, BDRV_OPT_AUTO_READ_ONLY, "on"); assert((bdrv_flags & BDRV_O_CACHE_MASK) == 0); if (runstate_check(RUN_STATE_INMIGRATE)) {