mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-20 07:59:00 +00:00
conf: Add the size of failed max_memory in error
If virDomainDefCompatibleDevice fails because there is insufficient domain def->mem.max_memory, then let's also print out that value in the error message. Signed-off-by: John Ferlan <jferlan@redhat.com> ACKed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
dd45c2710f
commit
4f0854e7df
@ -28926,7 +28926,8 @@ virDomainDefCompatibleDevice(virDomainDefPtr def,
|
|||||||
if ((virDomainDefGetMemoryTotal(def) + sz) > def->mem.max_memory) {
|
if ((virDomainDefGetMemoryTotal(def) + sz) > def->mem.max_memory) {
|
||||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
||||||
_("Attaching memory device with size '%llu' would "
|
_("Attaching memory device with size '%llu' would "
|
||||||
"exceed domain's maxMemory config"), sz);
|
"exceed domain's maxMemory config size '%llu'"),
|
||||||
|
sz, def->mem.max_memory);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user