Re: [PATCH v4 6/6] qemu-command: introduce new vgamem attribute for QXL video device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Pavel Hrdina <phrdina@xxxxxxxxxx> writes:

> diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
> index 6313d30..5c1b1de 100644
> --- a/src/conf/domain_conf.c
> +++ b/src/conf/domain_conf.c
> @@ -10272,6 +10272,7 @@ virDomainVideoDefParseXML(xmlNodePtr node,
>      char *heads = NULL;
>      char *vram = NULL;
>      char *ram = NULL;
> +    char *vgamem = NULL;
>      char *primary = NULL;
>  
>      if (VIR_ALLOC(def) < 0)
> @@ -10285,6 +10286,7 @@ virDomainVideoDefParseXML(xmlNodePtr node,
>                  type = virXMLPropString(cur, "type");
>                  ram = virXMLPropString(cur, "ram");
>                  vram = virXMLPropString(cur, "vram");
> +                vgamem = virXMLPropString(cur, "vgamem");
>                  heads = virXMLPropString(cur, "heads");
>  
>                  if ((primary = virXMLPropString(cur, "primary")) != NULL) {
> @@ -10338,6 +10340,19 @@ virDomainVideoDefParseXML(xmlNodePtr node,
>          def->vram = virDomainVideoDefaultRAM(dom, def->type);
>      }
>  
> +    if (vgamem) {
> +        if (def->type != VIR_DOMAIN_VIDEO_TYPE_QXL) {
> +            virReportError(VIR_ERR_XML_ERROR, "%s",
> +                           _("vgamem attribute only supported for type of qxl"));
> +            goto error;

Should libvirt ignore XML attributes that makes no sense for some
models and keep accepting a configuration that used to work before?

(I am replying to this old post, just because it caused a regression in
virt-manager)

Thanks,
Giuseppe

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]