2009-11-02 21:40:58 +08:00
|
|
|
/*
|
|
|
|
* QEMU live block migration
|
|
|
|
*
|
|
|
|
* Copyright IBM, Corp. 2009
|
|
|
|
*
|
|
|
|
* Authors:
|
|
|
|
* Liran Schour <lirans@il.ibm.com>
|
|
|
|
*
|
|
|
|
* This work is licensed under the terms of the GNU GPL, version 2. See
|
|
|
|
* the COPYING file in the top-level directory.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2016-06-29 16:12:57 +08:00
|
|
|
#ifndef MIGRATION_BLOCK_H
|
|
|
|
#define MIGRATION_BLOCK_H
|
2009-11-02 21:40:58 +08:00
|
|
|
|
2017-05-15 22:05:29 +08:00
|
|
|
#ifdef CONFIG_LIVE_BLOCK_MIGRATION
|
2009-12-01 01:21:21 +08:00
|
|
|
int blk_mig_active(void);
|
2017-09-26 18:33:16 +08:00
|
|
|
int blk_mig_bulk_active(void);
|
2009-12-01 01:21:21 +08:00
|
|
|
uint64_t blk_mig_bytes_transferred(void);
|
|
|
|
uint64_t blk_mig_bytes_remaining(void);
|
|
|
|
uint64_t blk_mig_bytes_total(void);
|
2009-12-01 01:21:20 +08:00
|
|
|
|
2017-05-15 22:05:29 +08:00
|
|
|
#else
|
|
|
|
static inline int blk_mig_active(void)
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
2017-09-26 18:33:16 +08:00
|
|
|
|
|
|
|
static inline int blk_mig_bulk_active(void)
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-05-15 22:05:29 +08:00
|
|
|
static inline uint64_t blk_mig_bytes_transferred(void)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
static inline uint64_t blk_mig_bytes_remaining(void)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
2017-04-06 00:32:37 +08:00
|
|
|
|
2017-05-15 22:05:29 +08:00
|
|
|
static inline uint64_t blk_mig_bytes_total(void)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
#endif /* CONFIG_LIVE_BLOCK_MIGRATION */
|
|
|
|
|
|
|
|
void migrate_set_block_enabled(bool value, Error **errp);
|
2016-06-29 16:12:57 +08:00
|
|
|
#endif /* MIGRATION_BLOCK_H */
|