mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-27 06:55:18 +00:00
qemu_process: Rename identifiers moved from qemu_capabilities
s/virQEMUCapsInitQMPCommand/qemuProcessQMP/ Signed-off-by: Chris Venteicher <cventeic@redhat.com> Reviewed-by: Jiri Denemark <jdenemar@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
16058045d0
commit
3bdb6e826f
@ -4361,15 +4361,15 @@ virQEMUCapsInitQMP(virQEMUCapsPtr qemuCaps,
|
|||||||
gid_t runGid,
|
gid_t runGid,
|
||||||
char **qmperr)
|
char **qmperr)
|
||||||
{
|
{
|
||||||
virQEMUCapsInitQMPCommandPtr cmd = NULL;
|
qemuProcessQMPPtr cmd = NULL;
|
||||||
int ret = -1;
|
int ret = -1;
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
if (!(cmd = virQEMUCapsInitQMPCommandNew(qemuCaps->binary, libDir,
|
if (!(cmd = qemuProcessQMPNew(qemuCaps->binary, libDir,
|
||||||
runUid, runGid, qmperr)))
|
runUid, runGid, qmperr)))
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
|
|
||||||
if ((rc = virQEMUCapsInitQMPCommandRun(cmd, false)) != 0) {
|
if ((rc = qemuProcessQMPRun(cmd, false)) != 0) {
|
||||||
if (rc == 1)
|
if (rc == 1)
|
||||||
ret = 0;
|
ret = 0;
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
@ -4379,8 +4379,8 @@ virQEMUCapsInitQMP(virQEMUCapsPtr qemuCaps,
|
|||||||
goto cleanup;
|
goto cleanup;
|
||||||
|
|
||||||
if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_KVM)) {
|
if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_KVM)) {
|
||||||
virQEMUCapsInitQMPCommandAbort(cmd);
|
qemuProcessQMPAbort(cmd);
|
||||||
if ((rc = virQEMUCapsInitQMPCommandRun(cmd, true)) != 0) {
|
if ((rc = qemuProcessQMPRun(cmd, true)) != 0) {
|
||||||
if (rc == 1)
|
if (rc == 1)
|
||||||
ret = 0;
|
ret = 0;
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
@ -4393,7 +4393,7 @@ virQEMUCapsInitQMP(virQEMUCapsPtr qemuCaps,
|
|||||||
ret = 0;
|
ret = 0;
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
virQEMUCapsInitQMPCommandFree(cmd);
|
qemuProcessQMPFree(cmd);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8325,12 +8325,12 @@ static qemuMonitorCallbacks callbacks = {
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
virQEMUCapsInitQMPCommandFree(virQEMUCapsInitQMPCommandPtr cmd)
|
qemuProcessQMPFree(qemuProcessQMPPtr cmd)
|
||||||
{
|
{
|
||||||
if (!cmd)
|
if (!cmd)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
virQEMUCapsInitQMPCommandAbort(cmd);
|
qemuProcessQMPAbort(cmd);
|
||||||
VIR_FREE(cmd->binary);
|
VIR_FREE(cmd->binary);
|
||||||
VIR_FREE(cmd->monpath);
|
VIR_FREE(cmd->monpath);
|
||||||
VIR_FREE(cmd->monarg);
|
VIR_FREE(cmd->monarg);
|
||||||
@ -8339,14 +8339,14 @@ virQEMUCapsInitQMPCommandFree(virQEMUCapsInitQMPCommandPtr cmd)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
virQEMUCapsInitQMPCommandPtr
|
qemuProcessQMPPtr
|
||||||
virQEMUCapsInitQMPCommandNew(char *binary,
|
qemuProcessQMPNew(char *binary,
|
||||||
const char *libDir,
|
const char *libDir,
|
||||||
uid_t runUid,
|
uid_t runUid,
|
||||||
gid_t runGid,
|
gid_t runGid,
|
||||||
char **qmperr)
|
char **qmperr)
|
||||||
{
|
{
|
||||||
virQEMUCapsInitQMPCommandPtr cmd = NULL;
|
qemuProcessQMPPtr cmd = NULL;
|
||||||
|
|
||||||
if (VIR_ALLOC(cmd) < 0)
|
if (VIR_ALLOC(cmd) < 0)
|
||||||
goto error;
|
goto error;
|
||||||
@ -8385,7 +8385,7 @@ virQEMUCapsInitQMPCommandNew(char *binary,
|
|||||||
return cmd;
|
return cmd;
|
||||||
|
|
||||||
error:
|
error:
|
||||||
virQEMUCapsInitQMPCommandFree(cmd);
|
qemuProcessQMPFree(cmd);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -8395,8 +8395,8 @@ virQEMUCapsInitQMPCommandNew(char *binary,
|
|||||||
* 1 when probing QEMU failed
|
* 1 when probing QEMU failed
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
virQEMUCapsInitQMPCommandRun(virQEMUCapsInitQMPCommandPtr cmd,
|
qemuProcessQMPRun(qemuProcessQMPPtr cmd,
|
||||||
bool forceTCG)
|
bool forceTCG)
|
||||||
{
|
{
|
||||||
virDomainXMLOptionPtr xmlopt = NULL;
|
virDomainXMLOptionPtr xmlopt = NULL;
|
||||||
const char *machine;
|
const char *machine;
|
||||||
@ -8474,7 +8474,7 @@ virQEMUCapsInitQMPCommandRun(virQEMUCapsInitQMPCommandPtr cmd,
|
|||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
if (!cmd->mon)
|
if (!cmd->mon)
|
||||||
virQEMUCapsInitQMPCommandAbort(cmd);
|
qemuProcessQMPAbort(cmd);
|
||||||
virObjectUnref(xmlopt);
|
virObjectUnref(xmlopt);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
@ -8486,7 +8486,7 @@ virQEMUCapsInitQMPCommandRun(virQEMUCapsInitQMPCommandPtr cmd,
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
virQEMUCapsInitQMPCommandAbort(virQEMUCapsInitQMPCommandPtr cmd)
|
qemuProcessQMPAbort(qemuProcessQMPPtr cmd)
|
||||||
{
|
{
|
||||||
if (cmd->mon)
|
if (cmd->mon)
|
||||||
virObjectUnlock(cmd->mon);
|
virObjectUnlock(cmd->mon);
|
||||||
|
@ -214,9 +214,9 @@ int qemuProcessStartManagedPRDaemon(virDomainObjPtr vm);
|
|||||||
|
|
||||||
void qemuProcessKillManagedPRDaemon(virDomainObjPtr vm);
|
void qemuProcessKillManagedPRDaemon(virDomainObjPtr vm);
|
||||||
|
|
||||||
typedef struct _virQEMUCapsInitQMPCommand virQEMUCapsInitQMPCommand;
|
typedef struct _qemuProcessQMP qemuProcessQMP;
|
||||||
typedef virQEMUCapsInitQMPCommand *virQEMUCapsInitQMPCommandPtr;
|
typedef qemuProcessQMP *qemuProcessQMPPtr;
|
||||||
struct _virQEMUCapsInitQMPCommand {
|
struct _qemuProcessQMP {
|
||||||
char *binary;
|
char *binary;
|
||||||
uid_t runUid;
|
uid_t runUid;
|
||||||
gid_t runGid;
|
gid_t runGid;
|
||||||
@ -231,17 +231,17 @@ struct _virQEMUCapsInitQMPCommand {
|
|||||||
virDomainObjPtr vm;
|
virDomainObjPtr vm;
|
||||||
};
|
};
|
||||||
|
|
||||||
virQEMUCapsInitQMPCommandPtr virQEMUCapsInitQMPCommandNew(char *binary,
|
qemuProcessQMPPtr qemuProcessQMPNew(char *binary,
|
||||||
const char *libDir,
|
const char *libDir,
|
||||||
uid_t runUid,
|
uid_t runUid,
|
||||||
gid_t runGid,
|
gid_t runGid,
|
||||||
char **qmperr);
|
char **qmperr);
|
||||||
|
|
||||||
void virQEMUCapsInitQMPCommandFree(virQEMUCapsInitQMPCommandPtr cmd);
|
void qemuProcessQMPFree(qemuProcessQMPPtr cmd);
|
||||||
|
|
||||||
int virQEMUCapsInitQMPCommandRun(virQEMUCapsInitQMPCommandPtr cmd,
|
int qemuProcessQMPRun(qemuProcessQMPPtr cmd,
|
||||||
bool forceTCG);
|
bool forceTCG);
|
||||||
|
|
||||||
void virQEMUCapsInitQMPCommandAbort(virQEMUCapsInitQMPCommandPtr cmd);
|
void qemuProcessQMPAbort(qemuProcessQMPPtr cmd);
|
||||||
|
|
||||||
#endif /* LIBVIRT_QEMU_PROCESS_H */
|
#endif /* LIBVIRT_QEMU_PROCESS_H */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user