1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2025-01-10 05:17:59 +03:00

qemu_validate: Fix capability check for disk queue_size

Commit ad209e7d adds QEMU_CAPS_VIRTIO_BLK_QUEUE_SIZE capability, but
the following commit 2d6d67e1 missed to use it and uses
QEMU_CAPS_VIRTIO_BLK_NUM_QUEUES instead.

This commit fixes the mistake.

Signed-off-by: Hiroki Narukawa <hnarukaw@yahoo-corp.jp>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Hiroki Narukawa 2021-10-15 19:11:49 +09:00 committed by Michal Privoznik
parent 0cddf1978c
commit d9afe162ab

View File

@ -2845,7 +2845,7 @@ qemuValidateDomainDeviceDefDiskFrontend(const virDomainDiskDef *disk,
return -1;
}
if (disk->queue_size > 0 &&
!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_BLK_NUM_QUEUES)) {
!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_BLK_QUEUE_SIZE)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("queue-size property isn't supported by this QEMU binary"));
return -1;