Particularly in qemuBuildNumaArgStr(), there was a need for the advice
due to memory backing, which needs to know the nodeset it will be pinned
to. With newer qemu this caused the following error when starting
domain:
error: internal error: Advice from numad is needed in case of
automatic numa placement
even when starting perfectly valid domain, e.g.:
...
<vcpu placement='auto'>4</vcpu>
<numatune>
<memory mode='strict' placement='auto'/>
</numatune>
<cpu>
<numa>
<cell id='0' cpus='0' memory='524288'/>
<cell id='1' cpus='1' memory='524288'/>
</numa>
</cpu>
...
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=
1138545
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
qemuBuildNumaArgStr(virQEMUDriverConfigPtr cfg,
const virDomainDef *def,
virCommandPtr cmd,
- virQEMUCapsPtr qemuCaps)
+ virQEMUCapsPtr qemuCaps,
+ virBitmapPtr nodeset)
{
size_t i, j;
virBuffer buf = VIR_BUFFER_INITIALIZER;
virBufferAsprintf(&buf, ",size=%dM,id=ram-node%zu", cellmem, i);
- if (virDomainNumatuneMaybeFormatNodeset(def->numatune, NULL,
+ if (virDomainNumatuneMaybeFormatNodeset(def->numatune, nodeset,
&nodemask, i) < 0)
goto cleanup;
virNetDevVPortProfileOp vmop,
qemuBuildCommandLineCallbacksPtr callbacks,
bool standalone,
- bool enableFips)
+ bool enableFips,
+ virBitmapPtr nodeset)
{
virErrorPtr originalError = NULL;
size_t i, j;
}
if (def->cpu && def->cpu->ncells)
- if (qemuBuildNumaArgStr(cfg, def, cmd, qemuCaps) < 0)
+ if (qemuBuildNumaArgStr(cfg, def, cmd, qemuCaps, nodeset) < 0)
goto error;
if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_UUID))
virNetDevVPortProfileOp vmop,
qemuBuildCommandLineCallbacksPtr callbacks,
bool forXMLToArgv,
- bool enableFips)
+ bool enableFips,
+ virBitmapPtr nodeset)
ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(11);
/* Generate '-device' string for chardev device */
VIR_NETDEV_VPORT_PROFILE_OP_NO_OP,
&buildCommandLineCallbacks,
true,
- qemuCheckFips())))
+ qemuCheckFips(),
+ NULL)))
goto cleanup;
ret = virCommandToString(cmd);
priv->monJSON, priv->qemuCaps,
migrateFrom, stdin_fd, snapshot, vmop,
&buildCommandLineCallbacks, false,
- qemuCheckFips())))
+ qemuCheckFips(),
+ nodemask)))
goto cleanup;
/* now that we know it is about to start call the hook if present */
migrateFrom, migrateFd, NULL,
VIR_NETDEV_VPORT_PROFILE_OP_NO_OP,
&testCallbacks, false,
- (flags & FLAG_FIPS)))) {
+ (flags & FLAG_FIPS),
+ NULL))) {
if (!virtTestOOMActive() &&
(flags & FLAG_EXPECT_FAILURE)) {
ret = 0;
vmdef, &monitor_chr, json, extraFlags,
migrateFrom, migrateFd, NULL,
VIR_NETDEV_VPORT_PROFILE_OP_NO_OP,
- &testCallbacks, false, false)))
+ &testCallbacks, false, false, NULL)))
goto fail;
if (!virtTestOOMActive()) {