MemLock is already used in other modules and, while still an abbreviation, is not ambiguous. --- src/qemu/qemu_command.c | 4 ++-- src/qemu/qemu_domain.c | 10 +++++----- src/qemu/qemu_domain.h | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 4d00fd9..f6c41ce 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -11095,8 +11095,8 @@ qemuBuildCommandLine(virConnectPtr conn, /* In some situations, eg. VFIO passthrough, QEMU might need to lock a * significant amount of memory, so we need to set the limit accordingly */ - if (qemuDomainRequiresMlock(def)) - virCommandSetMaxMemLock(cmd, qemuDomainGetMlockLimitBytes(def)); + if (qemuDomainRequiresMemLock(def)) + virCommandSetMaxMemLock(cmd, qemuDomainGetMemLockLimitBytes(def)); if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_MSG_TIMESTAMP) && cfg->logTimestamp) diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 51a1770..1521213 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -3802,7 +3802,7 @@ qemuDomainUpdateCurrentMemorySize(virQEMUDriverPtr driver, /** - * qemuDomainGetMlockLimitBytes: + * qemuDomainGetMemLockLimitBytes: * * @def: domain definition * @@ -3812,7 +3812,7 @@ qemuDomainUpdateCurrentMemorySize(virQEMUDriverPtr driver, * value returned may depend upon the architecture or devices present. */ unsigned long long -qemuDomainGetMlockLimitBytes(virDomainDefPtr def) +qemuDomainGetMemLockLimitBytes(virDomainDefPtr def) { unsigned long long memKB; @@ -3933,7 +3933,7 @@ qemuDomainGetMlockLimitBytes(virDomainDefPtr def) * requirements. * */ bool -qemuDomainRequiresMlock(virDomainDefPtr def) +qemuDomainRequiresMemLock(virDomainDefPtr def) { size_t i; @@ -3977,7 +3977,7 @@ qemuDomainAdjustMaxMemLock(virDomainObjPtr vm) unsigned long long bytes = 0; int ret = -1; - if (qemuDomainRequiresMlock(vm->def)) { + if (qemuDomainRequiresMemLock(vm->def)) { /* If this is the first time adjusting the limit, save the current * value so that we can restore it once memory locking is no longer * required */ @@ -3985,7 +3985,7 @@ qemuDomainAdjustMaxMemLock(virDomainObjPtr vm) if (virProcessGetMaxMemLock(vm->pid, &(vm->original_memlock)) < 0) goto out; } - bytes = qemuDomainGetMlockLimitBytes(vm->def); + bytes = qemuDomainGetMemLockLimitBytes(vm->def); } else { /* Once memory locking is no longer required, we can restore the * original, usually very low, limit */ diff --git a/src/qemu/qemu_domain.h b/src/qemu/qemu_domain.h index cc64df3..dcb9dc6 100644 --- a/src/qemu/qemu_domain.h +++ b/src/qemu/qemu_domain.h @@ -484,8 +484,8 @@ bool qemuDomainMachineHasBuiltinIDE(const virDomainDef *def); int qemuDomainUpdateCurrentMemorySize(virQEMUDriverPtr driver, virDomainObjPtr vm); -unsigned long long qemuDomainGetMlockLimitBytes(virDomainDefPtr def); -bool qemuDomainRequiresMlock(virDomainDefPtr def); +unsigned long long qemuDomainGetMemLockLimitBytes(virDomainDefPtr def); +bool qemuDomainRequiresMemLock(virDomainDefPtr def); int qemuDomainAdjustMaxMemLock(virDomainObjPtr vm); int qemuDomainDefValidateMemoryHotplug(const virDomainDef *def, -- 2.5.0 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list