Revert "conf: Skip post parse callbacks when creating copy"

This breaks vCPU hotplug, because when starting a domain, we
create a copy of domain definition (which becomes live XML) and
during the post parse callbacks we might adjust some tunings so
that vCPU hotplug is possible.

This reverts commit 581b7756af.
This commit is contained in:
Michal Privoznik 2016-10-04 18:00:02 +02:00
parent ddc8bc1cf4
commit 8cfdd6e4f5
2 changed files with 3 additions and 6 deletions

View File

@ -24684,8 +24684,7 @@ virDomainDefCopy(virDomainDefPtr src,
virDomainDefPtr ret;
unsigned int format_flags = VIR_DOMAIN_DEF_FORMAT_SECURE;
unsigned int parse_flags = VIR_DOMAIN_DEF_PARSE_INACTIVE |
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE |
VIR_DOMAIN_DEF_PARSE_SKIP_POST_PARSE;
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE;
if (migratable)
format_flags |= VIR_DOMAIN_DEF_FORMAT_INACTIVE | VIR_DOMAIN_DEF_FORMAT_MIGRATABLE;
@ -25172,8 +25171,7 @@ virDomainDeviceDefCopy(virDomainDeviceDefPtr src,
xmlStr = virBufferContentAndReset(&buf);
ret = virDomainDeviceDefParse(xmlStr, def, caps, xmlopt,
VIR_DOMAIN_DEF_PARSE_INACTIVE |
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE |
VIR_DOMAIN_DEF_PARSE_SKIP_POST_PARSE);
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE);
cleanup:
VIR_FREE(xmlStr);

View File

@ -3380,8 +3380,7 @@ qemuDomainDefCopy(virQEMUDriverPtr driver,
if (!(ret = virDomainDefParseString(xml, caps, driver->xmlopt, NULL,
VIR_DOMAIN_DEF_PARSE_INACTIVE |
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE |
VIR_DOMAIN_DEF_PARSE_SKIP_POST_PARSE)))
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE)))
goto cleanup;
cleanup: