[PATCH 16/30] qemuDomainValidateStorageSource: Validate new network storage parameters

Ján Tomko jtomko at redhat.com
Fri Mar 13 05:41:54 UTC 2020


On a Monday in 2020, Peter Krempa wrote:
>Ensure that the new fields are allowed only when -blockdev is used or
>when they are in the detected part of the backing chain where qemu will
>handle them internally.
>
>Signed-off-by: Peter Krempa <pkrempa at redhat.com>
>---
> src/qemu/qemu_domain.c | 55 ++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 55 insertions(+)
>
>diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
>index 1d551f248f..e7aaded4d5 100644
>--- a/src/qemu/qemu_domain.c
>+++ b/src/qemu/qemu_domain.c
>+
>+    if (src->readahead > 0) {
>+        if (!src->detected &&

Is this supported for non-network sources?

>+            !virQEMUCapsGet(qemuCaps, QEMU_CAPS_BLOCKDEV)) {
>+            virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
>+                           _("readahead setting is not supported by this QEMU binary"));

Either way - readahead in QEMU's curl backend seems to be there for a
long time now. "supported with this QEMU binary" would be more accurate phrasing

>+            return -1;
>+        }

Reviewed-by: Ján Tomko <jtomko at redhat.com>

Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20200313/989655ab/attachment-0001.sig>


More information about the libvir-list mailing list