]> xenbits.xensource.com Git - libvirt.git/commitdiff
ch: Explicitly forbid live changing nodeset for strict numatune
authorMichal Privoznik <mprivozn@redhat.com>
Fri, 1 Apr 2022 13:35:58 +0000 (15:35 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Thu, 7 Apr 2022 10:12:08 +0000 (12:12 +0200)
This is similar to v7.10.0-354-g06f405c627 except this time it
fixes CH driver.

With strict numatune we can't guarantee that all memory is moved
to new location. Therefore, let's forbid moving memory in that
case. However, allow it for restrictive mode, which is documented
to be best effort.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/ch/ch_driver.c

index 2fe7aba9d0c5f9a2406579522e756efedbf05ca5..34ce0c1a0cd8e36bae8fdd95298135c71d481591 100644 (file)
@@ -1519,7 +1519,7 @@ chDomainSetNumaParamsLive(virDomainObj *vm,
     size_t i = 0;
 
     if (virDomainNumatuneGetMode(vm->def->numa, -1, &mode) == 0 &&
-        mode != VIR_DOMAIN_NUMATUNE_MEM_STRICT) {
+        mode != VIR_DOMAIN_NUMATUNE_MEM_RESTRICTIVE) {
         virReportError(VIR_ERR_OPERATION_INVALID, "%s",
                        _("change of nodeset for running domain requires strict numa mode"));
         return -1;