This patch update domstats command to support CMT feature based on
extended bulk stats API virDomainListGetStats.
Signed-off-by: Qiaowei Ren <qiaowei.ren(a)intel.com>
---
tools/virsh-domain-monitor.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/tools/virsh-domain-monitor.c b/tools/virsh-domain-monitor.c
index 1d4dc25..28f7bf8 100644
--- a/tools/virsh-domain-monitor.c
+++ b/tools/virsh-domain-monitor.c
@@ -2013,6 +2013,10 @@ static const vshCmdOptDef opts_domstats[] = {
.type = VSH_OT_BOOL,
.help = N_("report domain block device statistics"),
},
+ {.name = "cache",
+ .type = VSH_OT_BOOL,
+ .help = N_("report domain cache statistics"),
+ },
{.name = "list-active",
.type = VSH_OT_BOOL,
.help = N_("list only active domains"),
@@ -2123,6 +2127,9 @@ cmdDomstats(vshControl *ctl, const vshCmd *cmd)
if (vshCommandOptBool(cmd, "block"))
stats |= VIR_DOMAIN_STATS_BLOCK;
+ if (vshCommandOptBool(cmd, "cache"))
+ stats |= VIR_DOMAIN_STATS_CACHE;
+
if (vshCommandOptBool(cmd, "list-active"))
flags |= VIR_CONNECT_GET_ALL_DOMAINS_STATS_ACTIVE;
--
1.9.1