qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PULL 09/12] migration: Fix postcopy bw for recovery


From: Dr. David Alan Gilbert (git)
Subject: [Qemu-devel] [PULL 09/12] migration: Fix postcopy bw for recovery
Date: Thu, 12 Sep 2019 14:50:03 +0100

From: Peter Xu <address@hidden>

We've got max-postcopy-bandwidth parameter but it's not applied
correctly after a postcopy recovery so the recovered migration stream
will still eat the whole net bandwidth.  Fix that up.

Reported-by: Xiaohui Li <address@hidden>
Signed-off-by: Peter Xu <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Juan Quintela <address@hidden>
Signed-off-by: Dr. David Alan Gilbert <address@hidden>
---
 migration/migration.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/migration/migration.c b/migration/migration.c
index 2391a8d418..e45270c23b 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -3336,7 +3336,8 @@ void migrate_fd_connect(MigrationState *s, Error 
*error_in)
 
     if (resume) {
         /* This is a resumed migration */
-        rate_limit = INT64_MAX;
+        rate_limit = s->parameters.max_postcopy_bandwidth /
+            XFER_LIMIT_RATIO;
     } else {
         /* This is a fresh new migration */
         rate_limit = s->parameters.max_bandwidth / XFER_LIMIT_RATIO;
-- 
2.21.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]