diff options
author | Peter Xu <peterx@redhat.com> | 2025-01-14 18:07:34 -0500 |
---|---|---|
committer | Fabiano Rosas <farosas@suse.de> | 2025-01-29 11:56:40 -0300 |
commit | 812145fcf7a6d290b69383dc5f25ed00360639d8 (patch) | |
tree | 9befc9b2fa34717cc333338bbeff820b7f16f58d | |
parent | 9cde9b435a7d14ce39331935f4dfea4778400048 (diff) | |
download | qemu-812145fcf7a6d290b69383dc5f25ed00360639d8.zip qemu-812145fcf7a6d290b69383dc5f25ed00360639d8.tar.gz qemu-812145fcf7a6d290b69383dc5f25ed00360639d8.tar.bz2 |
migration: Avoid two src-downtime-end tracepoints for postcopy
Postcopy can trigger this tracepoint twice, while only the 1st one is
valid. Avoid triggering the 2nd tracepoint just like what we do with
recording the total downtime.
Signed-off-by: Peter Xu <peterx@redhat.com>
Tested-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Juraj Marcin <jmarcin@redhat.com>
Link: https://lore.kernel.org/r/20250114230746.3268797-5-peterx@redhat.com
Signed-off-by: Fabiano Rosas <farosas@suse.de>
-rw-r--r-- | migration/migration.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/migration/migration.c b/migration/migration.c index a9fe9c2..07b6b73 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -129,9 +129,8 @@ static void migration_downtime_end(MigrationState *s) */ if (!s->downtime) { s->downtime = now - s->downtime_start; + trace_vmstate_downtime_checkpoint("src-downtime-end"); } - - trace_vmstate_downtime_checkpoint("src-downtime-end"); } static bool migration_needs_multiple_sockets(void) |