From: Paolo Bonzini <pbonzini@redhat.com>
To: Peter Xu <peterx@redhat.com>
Cc: qemu-stable@nongnu.org, qemu-devel@nongnu.org, dgilbert@redhat.com
Subject: Re: [PATCH 2/2] kvm: clear dirty bitmaps from all overlapping memslots
Date: Fri, 20 Sep 2019 16:03:00 +0200 [thread overview]
Message-ID: <09f006cf-d1ee-4639-50c8-cf8eb95d4fc2@redhat.com> (raw)
In-Reply-To: <20190920121813.GH12858@xz-x1>
On 20/09/19 14:18, Peter Xu wrote:
> (1) memory region aliasing, hence multiple GPAs can point to the same
> HVA/HPA so we need to clear the memslot dirty bits on all the
> mapped GPAs, and,
>
> (2) large log_clear() request which can cover more than one valid
> kvm memslots. Note that in this case, the mem slots can really
> be having different HVAs so imho it should be a different issue
> comparing to (1)
>
> The commit message says it's solving problem (1). However for what I
> understand, we are actually doing well on issue (1) because in
> memory_region_clear_dirty_bitmap() we iterate over all the flat views
> so that we should have caught all the aliasing memory regions if there
> are any.
There could be two addresses pointing to the same HVA *in the same
flatview*. See for example 0xe0000..0xfffff and 0xffffe000..0xffffffff
when a PC guest is started. In this particular case
0xffffe000..0xffffffff is ROM, so it's not an issue, but in other cases
it may
> However this patch should perfectly fix problem (2). Am I right?
I hadn't thought of problem (2). I guess without Igor's work for s390
it does not exist? But yes, it fixes it just the same.
Paolo
next prev parent reply other threads:[~2019-09-20 14:05 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-20 10:21 [PATCH 0/2] kvm: clear dirty bitmaps from all overlapping memslots Paolo Bonzini
2019-09-20 10:21 ` [PATCH 1/2] kvm: extract kvm_log_clear_one_slot Paolo Bonzini
2019-09-20 12:11 ` Peter Xu
2019-09-20 10:21 ` [PATCH 2/2] kvm: clear dirty bitmaps from all overlapping memslots Paolo Bonzini
2019-09-20 12:18 ` Peter Xu
2019-09-20 14:03 ` Paolo Bonzini [this message]
2019-09-20 12:19 ` [PATCH 0/2] " Peter Xu
2019-09-20 13:58 ` Igor Mammedov
2019-09-23 1:29 ` Peter Xu
2019-09-23 16:15 ` Igor Mammedov
2019-09-23 16:49 ` Paolo Bonzini
2019-09-24 2:53 ` Peter Xu
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=09f006cf-d1ee-4639-50c8-cf8eb95d4fc2@redhat.com \
--to=pbonzini@redhat.com \
--cc=dgilbert@redhat.com \
--cc=peterx@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-stable@nongnu.org \
/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).