diff --git a/qemu/tests/balloon_check.py b/qemu/tests/balloon_check.py index 0f8861d1c6..ce2ef0157a 100644 --- a/qemu/tests/balloon_check.py +++ b/qemu/tests/balloon_check.py @@ -461,7 +461,8 @@ def error_report(self, step, expect_value, monitor_value, guest_value): error_msg = "Wanted to be changed: %s\n" % (expect_value - self.pre_mem) if monitor_value: error_msg += "Changed in monitor: %s\n" % (monitor_value - self.pre_mem) - error_msg += "Changed in guest: %s\n" % (guest_value - self.pre_gmem) + # guest_value and pre_gmem is the memory in use in guest. + error_msg += "Changed in guest: %s\n" % (self.pre_gmem - guest_value) self.test.log.error(error_msg) def get_memory_status(self):