migration/multifd: Compute transferred bytes correctly
commitcbec7eb76879d419e7dbf531ee2506ec0722e825
authorJuan Quintela <quintela@redhat.com>
Mon, 15 May 2023 19:57:09 +0000 (15 21:57 +0200)
committerJuan Quintela <quintela@redhat.com>
Thu, 18 May 2023 16:41:46 +0000 (18 18:41 +0200)
tree2564b5bdcf643dd28e4f5a7c986b40887a79978b
parentbd7ceaf6d584b77dd6dbd8af7949d1e91a7c0537
migration/multifd: Compute transferred bytes correctly

In the past, we had to put the in the main thread all the operations
related with sizes due to qemu_file not beeing thread safe.  As now
all counters are atomic, we can update the counters just after the
do the write.  As an aditional bonus, we are able to use the right
value for the compression methods.  Right now we were assuming that
there were no compression at all.

Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Message-Id: <20230515195709.63843-17-quintela@redhat.com>
migration/multifd.c