qemu: process: Remove 'retry' argument from qemuConnectMonitor

Both callers pass 'false' as the argument via a variable which is not
modified. Remove the argument and pass 'false' directly.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Jonathon Jongsma <jjongsma@redhat.com>
This commit is contained in:
Peter Krempa 2022-08-02 13:36:47 +02:00
parent 288a297df5
commit d79216188d
1 changed files with 5 additions and 10 deletions

View File

@ -1883,7 +1883,6 @@ static int
qemuConnectMonitor(virQEMUDriver *driver, qemuConnectMonitor(virQEMUDriver *driver,
virDomainObj *vm, virDomainObj *vm,
int asyncJob, int asyncJob,
bool retry,
qemuDomainLogContext *logCtxt, qemuDomainLogContext *logCtxt,
bool reconnect) bool reconnect)
{ {
@ -1907,7 +1906,7 @@ qemuConnectMonitor(virQEMUDriver *driver,
mon = qemuMonitorOpen(vm, mon = qemuMonitorOpen(vm,
priv->monConfig, priv->monConfig,
retry, false,
timeout, timeout,
virEventThreadGetContext(priv->eventThread), virEventThreadGetContext(priv->eventThread),
&monitorCallbacks); &monitorCallbacks);
@ -2345,12 +2344,10 @@ qemuProcessWaitForMonitor(virQEMUDriver *driver,
int ret = -1; int ret = -1;
g_autoptr(GHashTable) info = NULL; g_autoptr(GHashTable) info = NULL;
qemuDomainObjPrivate *priv = vm->privateData; qemuDomainObjPrivate *priv = vm->privateData;
bool retry = false;
VIR_DEBUG("Connect monitor to vm=%p name='%s' retry=%d", VIR_DEBUG("Connect monitor to vm=%p name='%s'", vm, vm->def->name);
vm, vm->def->name, retry);
if (qemuConnectMonitor(driver, vm, asyncJob, retry, logCtxt, false) < 0) if (qemuConnectMonitor(driver, vm, asyncJob, logCtxt, false) < 0)
goto cleanup; goto cleanup;
/* Try to get the pty path mappings again via the monitor. This is much more /* Try to get the pty path mappings again via the monitor. This is much more
@ -8877,7 +8874,6 @@ qemuProcessReconnect(void *opaque)
size_t i; size_t i;
unsigned int stopFlags = 0; unsigned int stopFlags = 0;
bool jobStarted = false; bool jobStarted = false;
bool retry = false;
bool tryMonReconn = false; bool tryMonReconn = false;
virIdentitySetCurrent(data->identity); virIdentitySetCurrent(data->identity);
@ -8916,13 +8912,12 @@ qemuProcessReconnect(void *opaque)
if (qemuDomainObjStartWorker(obj) < 0) if (qemuDomainObjStartWorker(obj) < 0)
goto error; goto error;
VIR_DEBUG("Reconnect monitor to def=%p name='%s' retry=%d", VIR_DEBUG("Reconnect monitor to def=%p name='%s'", obj, obj->def->name);
obj, obj->def->name, retry);
tryMonReconn = true; tryMonReconn = true;
/* XXX check PID liveliness & EXE path */ /* XXX check PID liveliness & EXE path */
if (qemuConnectMonitor(driver, obj, VIR_ASYNC_JOB_NONE, retry, NULL, true) < 0) if (qemuConnectMonitor(driver, obj, VIR_ASYNC_JOB_NONE, NULL, true) < 0)
goto error; goto error;
priv->machineName = qemuDomainGetMachineName(obj); priv->machineName = qemuDomainGetMachineName(obj);