From: Zhang Chen <zhangckid@gmail.com>
To: qemu-devel <qemu-devel@nongnu.org>,
"Eric Blake" <eblake@redhat.com>,
"Markus Armbruster" <armbru@redhat.com>,
"'Michael S . Tsirkin'" <mst@redhat.com>,
"Stefan Hajnoczi" <stefanha@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"'Daniel P . Berrangé'" <berrange@redhat.com>,
"Jason Wang" <jasowangio@gmail.com>
Cc: Zhang Chen <zhangckid@gmail.com>
Subject: [PATCH V16 11/13] monitor/hmp: display IOThread holders
Date: Fri, 11 Sep 2026 18:07:07 +0800 [thread overview]
Message-ID: <20260911100709.726366-12-zhangckid@gmail.com> (raw)
In-Reply-To: <20260911100709.726366-1-zhangckid@gmail.com>
Display holder information in info iothreads to aid manual debugging.
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Zhang Chen <zhangckid@gmail.com>
---
monitor/hmp-cmds.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
index 91701ddf33..d7dd24d951 100644
--- a/monitor/hmp-cmds.c
+++ b/monitor/hmp-cmds.c
@@ -246,11 +246,31 @@ void hmp_info_iothreads(MonitorHMP *hmp, const QDict *qdict)
IOThreadInfoList *info_list = qmp_query_iothreads(NULL);
IOThreadInfoList *info;
IOThreadInfo *value;
+ IOThreadHolderList *h;
for (info = info_list; info; info = info->next) {
value = info->value;
monitor_hmp_printf(hmp, "%s:\n", value->id);
monitor_hmp_printf(hmp, " thread_id=%" PRId64 "\n", value->thread_id);
+ monitor_hmp_printf(hmp, " holders=");
+ for (h = value->holders; h; h = h->next) {
+ IOThreadHolder *holder = h->value;
+
+ switch (holder->type) {
+ case IO_THREAD_HOLDER_KIND_BLOCK_EXPORT:
+ monitor_hmp_printf(hmp, "[block-export: %s]",
+ holder->u.block_export.export_id);
+ break;
+ case IO_THREAD_HOLDER_KIND_QOM_OBJECT:
+ monitor_hmp_printf(hmp, "[qom-path: %s]",
+ holder->u.qom_object.qom_path);
+ break;
+ default:
+ g_assert_not_reached();
+ }
+ }
+ monitor_hmp_printf(hmp, "\n");
+
monitor_hmp_printf(hmp, " poll-max-ns=%" PRId64 "\n", value->poll_max_ns);
monitor_hmp_printf(hmp, " poll-grow=%" PRId64 "\n", value->poll_grow);
monitor_hmp_printf(hmp, " poll-shrink=%" PRId64 "\n", value->poll_shrink);
--
2.43.0
next prev parent reply other threads:[~2026-09-11 10:08 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-11 10:06 [PATCH V16 00/13] iothread: Support tracking and querying IOThread holder Zhang Chen
2026-09-11 10:06 ` [PATCH V16 01/13] iothread: introduce holder tracking Zhang Chen
2026-09-11 10:06 ` [PATCH V16 02/13] iothread: add holder-aware AioContext accessors Zhang Chen
2026-09-11 10:06 ` [PATCH V16 03/13] block/export: track IOThread references Zhang Chen
2026-09-11 10:07 ` [PATCH V16 04/13] monitor: track IOThread users with QOM paths Zhang Chen
2026-09-11 10:07 ` [PATCH V16 05/13] virtio-vq-mapping: track iothread-vq-mapping references using device path Zhang Chen
2026-09-11 10:07 ` [PATCH V16 06/13] virtio: track IOThread references for thread pinning Zhang Chen
2026-09-11 10:07 ` [PATCH V16 07/13] net/colo: track IOThread references using path-based holder Zhang Chen
2026-09-11 10:07 ` [PATCH V16 08/13] virtio-balloon: Update tracking iothread users with holder Zhang Chen
2026-09-11 10:07 ` [PATCH V16 09/13] vfio-user/proxy: Update tracking iothread users with holder name Zhang Chen
2026-09-11 10:07 ` [PATCH V16 10/13] xen-block: " Zhang Chen
2026-09-11 10:07 ` Zhang Chen [this message]
2026-09-11 10:07 ` [PATCH V16 12/13] iothread: make legacy AioContext getter explicitly unsafe Zhang Chen
2026-09-11 10:07 ` [PATCH V16 13/13] tests/unit/iothread: update AioContext ref/put helpers Zhang Chen
2026-09-11 10:52 ` [PATCH V16 00/13] iothread: Support tracking and querying IOThread holder Markus Armbruster
2026-09-11 12:53 ` Zhang Chen
2026-09-11 13:36 ` Markus Armbruster
2026-09-11 14:26 ` Zhang Chen
2026-09-15 7:33 ` Markus Armbruster
2026-09-15 9:47 ` Zhang Chen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260911100709.726366-12-zhangckid@gmail.com \
--to=zhangckid@gmail.com \
--cc=armbru@redhat.com \
--cc=berrange@redhat.com \
--cc=eblake@redhat.com \
--cc=jasowangio@gmail.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.