diff options
author | Peter Xu | 2022-07-07 20:55:06 +0200 |
---|---|---|
committer | Dr. David Alan Gilbert | 2022-07-20 13:15:08 +0200 |
commit | 60bb3c5871a7f7b7cfff5d0a30a035e30cce8e42 (patch) | |
tree | ce2a2d6915b9ddb44bd1c2a976fa6e57f1a091bb /migration/trace-events | |
parent | migration: Postcopy preemption enablement (diff) | |
download | qemu-60bb3c5871a7f7b7cfff5d0a30a035e30cce8e42.tar.gz qemu-60bb3c5871a7f7b7cfff5d0a30a035e30cce8e42.tar.xz qemu-60bb3c5871a7f7b7cfff5d0a30a035e30cce8e42.zip |
migration: Postcopy recover with preempt enabled
To allow postcopy recovery, the ram fast load (preempt-only) dest QEMU thread
needs similar handling on fault tolerance. When ram_load_postcopy() fails,
instead of stopping the thread it halts with a semaphore, preparing to be
kicked again when recovery is detected.
A mutex is introduced to make sure there's no concurrent operation upon the
socket. To make it simple, the fast ram load thread will take the mutex during
its whole procedure, and only release it if it's paused. The fast-path socket
will be properly released by the main loading thread safely when there's
network failures during postcopy with that mutex held.
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
Message-Id: <20220707185506.27257-1-peterx@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'migration/trace-events')
-rw-r--r-- | migration/trace-events | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/migration/trace-events b/migration/trace-events index 69f311169a..0e385c3a07 100644 --- a/migration/trace-events +++ b/migration/trace-events @@ -270,6 +270,8 @@ mark_postcopy_blocktime_begin(uint64_t addr, void *dd, uint32_t time, int cpu, i mark_postcopy_blocktime_end(uint64_t addr, void *dd, uint32_t time, int affected_cpu) "addr: 0x%" PRIx64 ", dd: %p, time: %u, affected_cpu: %d" postcopy_pause_fault_thread(void) "" postcopy_pause_fault_thread_continued(void) "" +postcopy_pause_fast_load(void) "" +postcopy_pause_fast_load_continued(void) "" postcopy_ram_fault_thread_entry(void) "" postcopy_ram_fault_thread_exit(void) "" postcopy_ram_fault_thread_fds_core(int baseufd, int quitfd) "ufd: %d quitfd: %d" |