mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
rdma: introduce qemu_update_position()
RDMA writes happen asynchronously, and thus the performance accounting also needs to be able to occur asynchronously. This allows anybody to call into savevm.c to update both f->pos as well as into arch_init.c to update the acct_info structure with up-to-date values when the RDMA transfer actually completes. Reviewed-by: Juan Quintela <quintela@redhat.com> Tested-by: Chegu Vinod <chegu_vinod@hp.com> Tested-by: Michael R. Hines <mrhines@us.ibm.com> Signed-off-by: Michael R. Hines <mrhines@us.ibm.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
f4abc9d621
commit
2b0ce0797d
4 changed files with 20 additions and 0 deletions
|
@ -92,6 +92,8 @@ uint64_t ram_bytes_remaining(void);
|
|||
uint64_t ram_bytes_transferred(void);
|
||||
uint64_t ram_bytes_total(void);
|
||||
|
||||
void acct_update_position(QEMUFile *f, size_t size, bool zero);
|
||||
|
||||
extern SaveVMHandlers savevm_ram_handlers;
|
||||
|
||||
uint64_t dup_mig_bytes_transferred(void);
|
||||
|
|
|
@ -93,6 +93,7 @@ void qemu_put_be32(QEMUFile *f, unsigned int v);
|
|||
void qemu_put_be64(QEMUFile *f, uint64_t v);
|
||||
int qemu_get_buffer(QEMUFile *f, uint8_t *buf, int size);
|
||||
int qemu_get_byte(QEMUFile *f);
|
||||
void qemu_update_position(QEMUFile *f, size_t size);
|
||||
|
||||
static inline unsigned int qemu_get_ubyte(QEMUFile *f)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue