summary refs log tree commit diff stats
path: root/migration/migration-stats.h
diff options
context:
space:
mode:
authorJuan Quintela <quintela@redhat.com>2023-05-15 21:56:54 +0200
committerJuan Quintela <quintela@redhat.com>2023-05-18 18:40:51 +0200
commit8e4b2a70599b3700b12b5a6059c819f81da9588c (patch)
treea4a65062bec28ec3e0314ebf1be741f17c0c2415 /migration/migration-stats.h
parentd0a14a2ba01c7b200e6ce3e7979e1ed3ede1d5c7 (diff)
downloadfocaccia-qemu-8e4b2a70599b3700b12b5a6059c819f81da9588c.tar.gz
focaccia-qemu-8e4b2a70599b3700b12b5a6059c819f81da9588c.zip
migration: Don't use INT64_MAX for unlimited rate
Define and use RATE_LIMIT_DISABLED instead.

Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Harsh Prateek Bora <harshpb@linux.ibm.com>
Message-Id: <20230515195709.63843-2-quintela@redhat.com>
Diffstat (limited to 'migration/migration-stats.h')
-rw-r--r--migration/migration-stats.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/migration/migration-stats.h b/migration/migration-stats.h
index cf8a4f0410..e7f1269769 100644
--- a/migration/migration-stats.h
+++ b/migration/migration-stats.h
@@ -16,6 +16,12 @@
 #include "qemu/stats64.h"
 
 /*
+ * If rate_limit_max is 0, there is special code to remove the rate
+ * limit.
+ */
+#define RATE_LIMIT_DISABLED 0
+
+/*
  * These are the ram migration statistic counters.  It is loosely
  * based on MigrationStats.  We change to Stat64 any counter that
  * needs to be updated using atomic ops (can be accessed by more than