From 8cfdd6e4f5d50a03bf34a0b22f167e5672c7678e Mon Sep 17 00:00:00 2001 From: Michal Privoznik Date: Tue, 4 Oct 2016 18:00:02 +0200 Subject: [PATCH] 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 581b7756af18dcf84b57d9947978725d2dfbfc18. --- src/conf/domain_conf.c | 6 ++---- src/qemu/qemu_domain.c | 3 +-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 1e65df1392..7427efbd31 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -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); diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 9b1a32ec38..2b24c01112 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -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: