Avi Kivity wrote:
Looks like we need to reintroduce a refcount bit in the pte, and check
the page using the VMA.
I don't think mucking with the VMA is going to help. We're already
using the VMA to determine that the region is MMIO. What we need to be
able to do is figure out, given a PFN, if that PFN is an MMIO page or
not. Really what we're looking for is whether we have to release a
reference to the page.
I think it would be sufficient to change kvm_release_pfn_clean() to
something like:
void kvm_release_pfn_clean(pfn_t pfn)
{
struct page *page;
if (!pfn_valid(pfn))
return;
page = pfn_to_page(pfn);
if (paeg_count(page))
put_page(page);
}
A couple other places need updating (like kvm_set_pfn_dirty()), but I
think the general idea would work.
Regards,
Anthony Liguori
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html