]> git.proxmox.com Git - mirror_qemu.git/commit - block.c
block: Allow changing 'detect-zeroes' on reopen
authorAlberto Garcia <berto@igalia.com>
Thu, 6 Sep 2018 09:37:09 +0000 (12:37 +0300)
committerKevin Wolf <kwolf@redhat.com>
Mon, 1 Oct 2018 10:51:12 +0000 (12:51 +0200)
commit543770bd2e8fbaac286a947dee91675adb3215c7
treebd89b70388a0f78a274719cc0408a9e874f633f5
parent593b30719713cfad98b869693095893f8edf76c1
block: Allow changing 'detect-zeroes' on reopen

'detect-zeroes' is one of the basic BlockdevOptions available for all
drivers, but it's not handled by bdrv_reopen_prepare(), so any attempt
to change it results in an error:

   (qemu) qemu-io virtio0 "reopen -o detect-zeroes=on"
   Cannot change the option 'detect-zeroes'

Since there's no reason why we shouldn't allow changing it and the
implementation is simple let's just do it.

Signed-off-by: Alberto Garcia <berto@igalia.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block.c
include/block/block.h