提交 8d5bba08 编写于 作者: W Wang Huaqiang 提交者: John Ferlan

qemu: Refactor qemuDomainGetStatsCpu

Refactoring qemuDomainGetStatsCpu, make it possible to add
more CPU statistics.
Signed-off-by: NWang Huaqiang <huaqiang.wang@intel.com>
Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
上级 0e56e6df
......@@ -19699,11 +19699,9 @@ typedef enum {
static int
qemuDomainGetStatsCpu(virQEMUDriverPtr driver ATTRIBUTE_UNUSED,
virDomainObjPtr dom,
virDomainStatsRecordPtr record,
int *maxparams,
unsigned int privflags ATTRIBUTE_UNUSED)
qemuDomainGetStatsCpuCgroup(virDomainObjPtr dom,
virDomainStatsRecordPtr record,
int *maxparams)
{
qemuDomainObjPrivatePtr priv = dom->privateData;
unsigned long long cpu_time = 0;
......@@ -19739,6 +19737,18 @@ qemuDomainGetStatsCpu(virQEMUDriverPtr driver ATTRIBUTE_UNUSED,
return 0;
}
static int
qemuDomainGetStatsCpu(virQEMUDriverPtr driver ATTRIBUTE_UNUSED,
virDomainObjPtr dom,
virDomainStatsRecordPtr record,
int *maxparams,
unsigned int privflags ATTRIBUTE_UNUSED)
{
return qemuDomainGetStatsCpuCgroup(dom, record, maxparams);
}
static int
qemuDomainGetStatsBalloon(virQEMUDriverPtr driver,
virDomainObjPtr dom,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册