From: Anthony Liguori <aliguori@us.ibm.com>
To: Avi Kivity <avi@qumranet.com>
Cc: Ben-Ami Yassour <benami@il.ibm.com>,
Han Weidong <weidong.han@intel.com>,
"Kay, Allen M" <allen.m.kay@intel.com>,
Muli Ben-Yehuda <muli@il.ibm.com>,
Amit Shah <amit.shah@qumranet.com>,
andrea@qumranet.com, kvm@vger.kernel.org,
Dave Hansen <haveblue@us.ibm.com>
Subject: Re: [PATCH] Handle vma regions with no backing page
Date: Wed, 04 Jun 2008 11:48:42 -0500 [thread overview]
Message-ID: <4846C76A.9070201@us.ibm.com> (raw)
In-Reply-To: <484664D9.6040407@qumranet.com>
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
next prev parent reply other threads:[~2008-06-04 16:49 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-03 11:17 [PATCH] Handle vma regions with no backing page Ben-Ami Yassour
2008-06-03 11:39 ` Andrea Arcangeli
2008-06-04 15:09 ` Ben-Ami Yassour
2008-06-04 16:17 ` Muli Ben-Yehuda
2008-06-04 19:34 ` Andrea Arcangeli
2008-06-04 19:41 ` Anthony Liguori
2008-06-04 19:51 ` Andrea Arcangeli
2008-06-04 19:59 ` Dave Hansen
2008-06-04 9:48 ` Avi Kivity
2008-06-04 16:48 ` Anthony Liguori [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-04-29 14:32 Anthony Liguori
2008-04-29 14:54 ` Andrea Arcangeli
2008-04-29 15:14 ` Anthony Liguori
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=4846C76A.9070201@us.ibm.com \
--to=aliguori@us.ibm.com \
--cc=allen.m.kay@intel.com \
--cc=amit.shah@qumranet.com \
--cc=andrea@qumranet.com \
--cc=avi@qumranet.com \
--cc=benami@il.ibm.com \
--cc=haveblue@us.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=muli@il.ibm.com \
--cc=weidong.han@intel.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