migration/block: Convert remaining DPRINTF() debug macro to trace events
Finish the conversion from commit fe80c0241d
("migration: using trace_ to replace DPRINTF").
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
c7a7db4b51
commit
163b8663b8
|
@ -42,16 +42,6 @@
|
||||||
#define MAX_IO_BUFFERS 512
|
#define MAX_IO_BUFFERS 512
|
||||||
#define MAX_PARALLEL_IO 16
|
#define MAX_PARALLEL_IO 16
|
||||||
|
|
||||||
/* #define DEBUG_BLK_MIGRATION */
|
|
||||||
|
|
||||||
#ifdef DEBUG_BLK_MIGRATION
|
|
||||||
#define DPRINTF(fmt, ...) \
|
|
||||||
do { printf("blk_migration: " fmt, ## __VA_ARGS__); } while (0)
|
|
||||||
#else
|
|
||||||
#define DPRINTF(fmt, ...) \
|
|
||||||
do { } while (0)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef struct BlkMigDevState {
|
typedef struct BlkMigDevState {
|
||||||
/* Written during setup phase. Can be read without a lock. */
|
/* Written during setup phase. Can be read without a lock. */
|
||||||
BlockBackend *blk;
|
BlockBackend *blk;
|
||||||
|
@ -502,7 +492,7 @@ static int blk_mig_save_bulked_block(QEMUFile *f)
|
||||||
block_mig_state.prev_progress = progress;
|
block_mig_state.prev_progress = progress;
|
||||||
qemu_put_be64(f, (progress << BDRV_SECTOR_BITS)
|
qemu_put_be64(f, (progress << BDRV_SECTOR_BITS)
|
||||||
| BLK_MIG_FLAG_PROGRESS);
|
| BLK_MIG_FLAG_PROGRESS);
|
||||||
DPRINTF("Completed %d %%\r", progress);
|
trace_migration_block_progression(progress);
|
||||||
}
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
|
@ -357,6 +357,7 @@ migration_block_flush_blks(const char *action, int submitted, int read_done, int
|
||||||
migration_block_save(const char *mig_stage, int submitted, int transferred) "Enter save live %s submitted %d transferred %d"
|
migration_block_save(const char *mig_stage, int submitted, int transferred) "Enter save live %s submitted %d transferred %d"
|
||||||
migration_block_save_complete(void) "Block migration completed"
|
migration_block_save_complete(void) "Block migration completed"
|
||||||
migration_block_state_pending(uint64_t pending) "Enter save live pending %" PRIu64
|
migration_block_state_pending(uint64_t pending) "Enter save live pending %" PRIu64
|
||||||
|
migration_block_progression(unsigned percent) "Completed %u%%"
|
||||||
|
|
||||||
# page_cache.c
|
# page_cache.c
|
||||||
migration_pagecache_init(int64_t max_num_items) "Setting cache buckets to %" PRId64
|
migration_pagecache_init(int64_t max_num_items) "Setting cache buckets to %" PRId64
|
||||||
|
|
Loading…
Reference in New Issue