[libvirt] [PATCH v4 6/6] qemu-command: introduce new vgamem attribute for QXL video device
Pavel Hrdina
phrdina at redhat.com
Mon Dec 1 12:19:36 UTC 2014
On 12/01/2014 12:53 PM, Giuseppe Scrivano wrote:
> Pavel Hrdina <phrdina at redhat.com> 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
>
The vgamem is a new attribute for QXL. The vram stil exists and its
only silently updated to proper value. The configuration with vram=9216
is wrong and should be updated in virt-manager tests.
Pavel
More information about the libvir-list
mailing list