From 3569664ee9f08c94a5a2c69f778f0d023e5e882f Mon Sep 17 00:00:00 2001 From: luzhipeng Date: Fri, 20 May 2022 10:19:35 +0800 Subject: qga: add guest-get-diskstats command for Linux guests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a new 'guest-get-diskstats' command for report disk io statistics for Linux guests. This can be useful for getting io flow or handling IO fault, no need to enter guests. Signed-off-by: luzhipeng Message-Id: <20220520021935.676-1-luzhipeng@cestc.cn> Reviewed-by: Marc-André Lureau Reviewed-by: Konstantin Kostiuk Signed-off-by: Konstantin Kostiuk --- qga/commands-win32.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qga/commands-win32.c') diff --git a/qga/commands-win32.c b/qga/commands-win32.c index d56b5fd2a7..dcdeb76a68 100644 --- a/qga/commands-win32.c +++ b/qga/commands-win32.c @@ -2532,3 +2532,9 @@ char *qga_get_host_name(Error **errp) return g_utf16_to_utf8(tmp, size, NULL, NULL, NULL); } + +GuestDiskStatsInfoList *qmp_guest_get_diskstats(Error **errp) +{ + error_setg(errp, QERR_UNSUPPORTED); + return NULL; +} -- cgit 1.4.1 From b9a002609fd887447eca8ee10777690d691f91d4 Mon Sep 17 00:00:00 2001 From: Konstantin Kostiuk Date: Tue, 24 May 2022 18:43:44 +0300 Subject: qga-win32: Add support for NVME bus type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bus type spaces (Indicates a storage spaces bus) is not supported, so return it as unknown. Signed-off-by: Konstantin Kostiuk Reviewed-by: Marc-André Lureau Message-Id: <20220524154344.869638-2-kkostiuk@redhat.com> Signed-off-by: Konstantin Kostiuk --- qga/commands-win32.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'qga/commands-win32.c') diff --git a/qga/commands-win32.c b/qga/commands-win32.c index dcdeb76a68..36f94c0f9c 100644 --- a/qga/commands-win32.c +++ b/qga/commands-win32.c @@ -490,6 +490,11 @@ static GuestDiskBusType win2qemu[] = { #if (_WIN32_WINNT >= 0x0601) [BusTypeVirtual] = GUEST_DISK_BUS_TYPE_VIRTUAL, [BusTypeFileBackedVirtual] = GUEST_DISK_BUS_TYPE_FILE_BACKED_VIRTUAL, + /* + * BusTypeSpaces currently is not suported + */ + [BusTypeSpaces] = GUEST_DISK_BUS_TYPE_UNKNOWN, + [BusTypeNvme] = GUEST_DISK_BUS_TYPE_NVME, #endif }; -- cgit 1.4.1