From: Wei Yang <richardw.yang@linux.intel.com>
To: qemu-devel@nongnu.org
Cc: Wei Yang <richardw.yang@linux.intel.com>,
dgilbert@redhat.com, quintela@redhat.com
Subject: [Qemu-devel] [PATCH] migratioin/ram.c: reset complete_round when we gets a queued page
Date: Wed, 5 Jun 2019 09:08:28 +0800 [thread overview]
Message-ID: <20190605010828.6969-1-richardw.yang@linux.intel.com> (raw)
In case we gets a queued page, the order of block is interrupted. We may
not rely on the complete_round flag to say we have already searched the
whole blocks on the list.
Signed-off-by: Wei Yang <richardw.yang@linux.intel.com>
---
migration/ram.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/migration/ram.c b/migration/ram.c
index d881981876..e9b40d636d 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -2290,6 +2290,12 @@ static bool get_queued_page(RAMState *rs, PageSearchStatus *pss)
*/
pss->block = block;
pss->page = offset >> TARGET_PAGE_BITS;
+
+ /*
+ * This unqueued page would break the "one round" check, even is
+ * really rare.
+ */
+ pss->complete_round = false;
}
return !!block;
--
2.19.1
next reply other threads:[~2019-06-05 1:09 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-05 1:08 Wei Yang [this message]
2019-06-05 6:41 ` [Qemu-devel] [PATCH] migratioin/ram.c: reset complete_round when we gets a queued page Peter Xu
2019-06-05 8:52 ` Wei Yang
2019-06-05 9:38 ` Peter Xu
2019-06-05 10:33 ` Juan Quintela
2019-06-05 13:39 ` Wei Yang
2019-06-05 13:41 ` Wei Yang
2019-06-05 12:27 ` Philippe Mathieu-Daudé
2019-06-05 13:39 ` Wei Yang
2019-06-05 14:11 ` Philippe Mathieu-Daudé
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190605010828.6969-1-richardw.yang@linux.intel.com \
--to=richardw.yang@linux.intel.com \
--cc=dgilbert@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).