All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Xu <peterx@redhat.com>
To: "Dr. David Alan Gilbert" <dave@treblig.org>
Cc: qemu-devel@nongnu.org, Fabiano Rosas <farosas@suse.de>,
	Prasad Pandit <ppandit@redhat.com>,
	Juraj Marcin <jmarcin@redhat.com>
Subject: Re: [PATCH v2 2/2] migration/hmp: Add "info migrate -a", reorg the dump
Date: Wed, 14 May 2025 17:17:02 -0400	[thread overview]
Message-ID: <aCUITicykC-ppJrv@x1.local> (raw)
In-Reply-To: <aCT9QRPd4cDSshGI@gallifrey>

On Wed, May 14, 2025 at 08:29:53PM +0000, Dr. David Alan Gilbert wrote:
> * Peter Xu (peterx@redhat.com) wrote:
> > A new parameter "-a" is added to "info migrate" to dump all info, while
> > when not specified it only dumps the important ones.  When at it, reorg
> > everything to make it easier to read for human.
> > 
> > The general rule is:
> > 
> >   - Put important things at the top
> >   - Reuse a single line when things are very relevant, hence reducing lines
> >     needed to show the results
> >   - Remove almost useless ones (e.g. "normal_bytes", while we also have
> >     both "page size" and "normal" pages)
> >   - Regroup things, so that related fields will show together
> >   - etc.
> 
> Thanks for the update,
> 
> Reviewed-by: Dr. David Alan Gilbert <dave@treblig.org>

Thanks for the quick comments!

> 
> Note that you did miss the change (which would be fine as a follow up)
> where I point out that I think your unit abbreviations are slightly wrong

Ouch, it's in the spam filter... :-( I would have missed that if you didn't
mention it. I would think any decent AI models would do better than this..
I have no idea how this could ever happen in 2025.

> (although I think I was wrong as well...)
> I think your throughput is in Mbps (capital M or Mb/s or Mbit/s) - ie.
> 10^6 bits/second.
> 
> While I think all your KB are KiB not KB (i.e. 2^10 bytes).

True..

Now I've read the missing reply:

https://lore.kernel.org/qemu-devel/aCSXjRCTYKbDf9le@gallifrey/

So yeh, mbps is in unit of bit, but all the rest needs fixing.  How about
below fixup to be squashed (if I won't need to repost for v3):

PS: in the fixup I also did s/psize/pagesize/ to be clear

diff --git a/migration/migration-hmp-cmds.c b/migration/migration-hmp-cmds.c
index 13e93d3c54..ea76f72fa4 100644
--- a/migration/migration-hmp-cmds.c
+++ b/migration/migration-hmp-cmds.c
@@ -111,9 +111,9 @@ void hmp_info_migrate(Monitor *mon, const QDict *qdict)
 
     if (info->ram) {
         monitor_printf(mon, "RAM info:\n");
-        monitor_printf(mon, "  Throughput (mbps): %0.2f\n",
+        monitor_printf(mon, "  Throughput (Mbps): %0.2f\n",
                        info->ram->mbps);
-        monitor_printf(mon, "  Sizes (KB): psize=%" PRIu64
+        monitor_printf(mon, "  Sizes (KiB): pagesize=%" PRIu64
                        ", total=%" PRIu64 "\n",
                        info->ram->page_size >> 10,
                        info->ram->total >> 10);

-- 
Peter Xu



  reply	other threads:[~2025-05-14 21:18 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-14 20:01 [PATCH v2 0/2] migration: Some fix and enhancements to HMP "info migrate" Peter Xu
2025-05-14 20:01 ` [PATCH v2 1/2] migration: Allow caps to be set when preempt or multifd cap enabled Peter Xu
2025-05-22 20:15   ` Michael Tokarev
2025-05-14 20:01 ` [PATCH v2 2/2] migration/hmp: Add "info migrate -a", reorg the dump Peter Xu
2025-05-14 20:29   ` Dr. David Alan Gilbert
2025-05-14 21:17     ` Peter Xu [this message]
2025-05-14 23:00       ` Dr. David Alan Gilbert
2025-05-21  8:43   ` Zhijian Li (Fujitsu) via
2025-05-21 14:03     ` Peter Xu
2025-05-21 21:04       ` Dr. David Alan Gilbert
2025-05-22  0:55         ` Zhijian Li (Fujitsu) via
2025-05-22 13:16           ` Peter Xu
2025-05-23  2:06             ` Zhijian Li (Fujitsu) via
2025-05-26 15:40               ` Peter Xu
2025-05-22  1:07       ` Zhijian Li (Fujitsu) via
2025-05-19 11:27 ` [PATCH v2 0/2] migration: Some fix and enhancements to HMP "info migrate" Mario Casquero
2025-05-20 17:03   ` Peter Xu

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=aCUITicykC-ppJrv@x1.local \
    --to=peterx@redhat.com \
    --cc=dave@treblig.org \
    --cc=farosas@suse.de \
    --cc=jmarcin@redhat.com \
    --cc=ppandit@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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.