mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
bhyve: add support for wiring memory
The <memoryBacking><locked/></memoryBacking> element will now pass the wired (-S) flag to the bhyve command. Signed-off-by: Fabian Freyer <fabian.freyer@physik.tu-berlin.de> Reviewed-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
This commit is contained in:
parent
65dd2ac92d
commit
b181e44d9f
@ -474,6 +474,9 @@ virBhyveProcessBuildBhyveCmd(virConnectPtr conn,
|
|||||||
virCommandAddArgFormat(cmd, "%llu",
|
virCommandAddArgFormat(cmd, "%llu",
|
||||||
VIR_DIV_UP(virDomainDefGetMemoryInitial(def), 1024));
|
VIR_DIV_UP(virDomainDefGetMemoryInitial(def), 1024));
|
||||||
|
|
||||||
|
if (def->mem.locked)
|
||||||
|
virCommandAddArg(cmd, "-S"); /* Wire guest memory */
|
||||||
|
|
||||||
/* Options */
|
/* Options */
|
||||||
if (def->features[VIR_DOMAIN_FEATURE_ACPI] == VIR_TRISTATE_SWITCH_ON)
|
if (def->features[VIR_DOMAIN_FEATURE_ACPI] == VIR_TRISTATE_SWITCH_ON)
|
||||||
virCommandAddArg(cmd, "-A"); /* Create an ACPI table */
|
virCommandAddArg(cmd, "-A"); /* Create an ACPI table */
|
||||||
|
@ -721,6 +721,9 @@ bhyveParseBhyveCommandLine(virDomainDefPtr def,
|
|||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case 'S':
|
||||||
|
def->mem.locked = true;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user