libxl: restore passing "readonly=" to qemu for SCSI disks
authorIan Jackson <ian.jackson@eu.citrix.com>
Wed, 13 Jun 2018 14:54:53 +0000 (15:54 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 22 Jun 2018 15:38:39 +0000 (16:38 +0100)
commitb929a87de46474cec537972b0a13fc0ec82343f1
tree5e5497f0b3ade27a6db4e9da87be41482bb26c6b
parent0bb180b734bedfdfe906c4bd57c289219803d471
libxl: restore passing "readonly=" to qemu for SCSI disks

A read-only check was introduced for XSA-142, commit ef6cb76026 ("libxl:
relax readonly check introduced by XSA-142 fix") added the passing of
the extra setting, but commit dab0539568 ("Introduce COLO mode and
refactor relevant function") dropped the passing of the setting again,
quite likely due to improper re-basing.

Restore the readonly= parameter to SCSI disks.  For IDE disks this is
supposed to be rejected; add an assert.  And there is a bare ad-hoc
disk drive string in libxl__build_device_model_args_new, which we also
update.

This is XSA-266.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
Gbp-Pq: Name libxl-restore-passing-readonly=-to-qemu-.patch
tools/libxl/libxl_dm.c