Skip to content

Commit

Permalink
virtio-blk: allow block_resize with dataplane
Browse files Browse the repository at this point in the history
Now that block_resize acquires the AioContext we can safely allow
resizing the disk.

Reported-by: Andrey Korolyov <andrey@xdel.ru>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
  • Loading branch information
stefanhaRH authored and kevmw committed Aug 20, 2014
1 parent 927e0e7 commit 466560b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions hw/block/dataplane/virtio-blk.c
Expand Up @@ -193,6 +193,7 @@ void virtio_blk_data_plane_create(VirtIODevice *vdev, VirtIOBlkConf *blk,

error_setg(&s->blocker, "block device is in use by data plane");
bdrv_op_block_all(blk->conf.bs, s->blocker);
bdrv_op_unblock(blk->conf.bs, BLOCK_OP_TYPE_RESIZE, s->blocker);

*dataplane = s;
}
Expand Down

0 comments on commit 466560b

Please sign in to comment.