Unlike other architectures, ppc64 domains need to lock memory
even when VFIO is not used.
Change qemuDomainRequiresMlock() to reflect this fact.
---
src/qemu/qemu_domain.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 1f73709..2c0f5af 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -3836,8 +3836,9 @@ qemuDomainGetMlockLimitBytes(virDomainDefPtr def)
/**
* @def: domain definition
*
- * Returns ture if the locked memory limit needs to be set or updated due to
- * configuration or passthrough devices.
+ * Returns true if the locked memory limit needs to be set or updated because
+ * of domain configuration, VFIO passthrough devices or architecture-specific
+ * requirements.
* */
bool
qemuDomainRequiresMlock(virDomainDefPtr def)
@@ -3847,6 +3848,10 @@ qemuDomainRequiresMlock(virDomainDefPtr def)
if (def->mem.locked)
return true;
+ /* ppc64 domains need to lock some memory even when VFIO is not used */
+ if (ARCH_IS_PPC64(def->os.arch))
+ return true;
+
for (i = 0; i < def->nhostdevs; i++) {
virDomainHostdevDefPtr dev = def->hostdevs[i];
--
2.5.0