Skip to content

allow to set 'drive' property on a realized block device

Denis Plotnikov qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v0 Latest2 patches 17 repliesIn review

Patches in v0 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2qdev-properties-system: extend set_pionter for unrealized deviceshw/core/qdev-properties-system.c+21 -115 replies
2/2block: allow to set 'drive' property on a realized block devicehw/core/qdev-properties-system.c+77 -127 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v0 yet.

Read the v0 thread

Cover letter [PATCH v0 0/2] allow to set 'drive' property on a realized block device

This allows to replace the file on a block device and is useful to workaround the cases (migration) when the VM image is placed on some shared storage with exclusive file opening model but the image should be open form more than one app.

The previous version of approaching the workaround was based on the "blockdev-change-medium" command modification but had some flaws:
* semantics: blockdev-change-medium is aimed to be used with removable devices only
* interface: it can't accept all possible combination of parameters for the "drive" replacement (creation).

More details here: http://patchwork.ozlabs.org/patch/1179329/

The current series suggests another approach:
1. blockdev-add
2. qom-set disk.drive = the blockdev added (this is what the series adds)

Denis Plotnikov (2):
qdev-properties-system: extend set_pionter for unrealized devices
block: allow to set 'drive' property on a realized block device

 hw/core/qdev-properties-system.c | 117 +++++++++++++++++++++++++------
 1 file changed, 96 insertions(+), 21 deletions(-)
Signature · 1 line
2.17.0