public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Anthony Liguori <aliguori-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
To: Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: kvm guest memory management
Date: Wed, 03 Oct 2007 10:03:19 -0500	[thread overview]
Message-ID: <4703AF37.7030602@us.ibm.com> (raw)
In-Reply-To: <46FF647E.6080506-atKUWr5tajBWk0Htik3J/w@public.gmane.org>

Avi Kivity wrote:
> Dong, Eddie wrote:
>   
>> There are couple reasons that g2h can't server this.
>> A VT-d device or EPT/NPT table need to translate from guest physical 
>> to machine physical address, while g2h uses host mode va as index.
>> Other reason is that g2h also include host user space memory & kernel
>> memory which guest should never touch. (A bad programmed VT-d device
>> may modify the memory listed by VT-d table).
>>
>>   
>>     
>
> For EPT, we can't use the host page tables because EPT does not support 
> the dirty bit.  So EPT requires duplication of the page tables anyway.
>   

EPT fill in the dirty bit?  To track dirty memory, you would have to
read protect portions of the EPT?  That seems quite unfortunate...

Regards,

Anthony Liguori

>> Dirty tracking can certainly be serviced even using p2m solely.
>>
>>   
>>     
>>> User-allocated memory will enable the following features:
>>> - s390 support
>>> - guest swapping
>>> - page migration (where a guest is migrated from one NUMA node
>>> to another)
>>> - in conjunction with a de-duplicating file system, page sharing
>>> among guests 
>>> - inter-guest shared memory (mmap() one file in two or more guests)
>>> - easier use of huge pages
>>> - more?
>>>
>>>     
>>>       
>> This doesn't conflict with my suggestion though the p2m table then
>> need to be dynamically modifed in case swapping happens.
>>   
>>     
>
> The nice thing about using the host page tables is that it's 
> automatically updated to reflect changes in mapping.  Translating a page 
> (gfn_to_page) becomes a call to get_user_pages().
>
>
>   



-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/

  parent reply	other threads:[~2007-10-03 15:03 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-25  5:52 [RFC][PATCH]Memory mapped TPR shadow feature enabling Yang, Sheng
     [not found] ` <DB3BD37E3533EE46BED2FBA80995557F87DA24-wq7ZOvIWXbM/UvCtAeCM4rfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-09-25  8:35   ` Avi Kivity
     [not found]     ` <46F8C84F.7090605-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-09-28  4:49       ` [RFC][PATCH]Memory mapped TPR shadow featureenabling Dong, Eddie
     [not found]         ` <10EA09EFD8728347A513008B6B0DA77A022AE787-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-09-28 14:41           ` Avi Kivity
     [not found]             ` <46FD1288.9030507-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-09-28 15:48               ` Dong, Eddie
     [not found]                 ` <10EA09EFD8728347A513008B6B0DA77A022AEA2F-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-09-28 16:22                   ` Windows 2003 Server SMP Guest crashes Fabian Deutsch
     [not found]                     ` <20070928162210.98710-hi6Y0CQ0nG0@public.gmane.org>
2007-09-28 16:57                       ` Avi Kivity
     [not found]                         ` <46FD3295.5020700-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-09-28 16:52                           ` Fabian Deutsch
2007-09-28 16:56                   ` kvm guest memory management (was: Re: [RFC][PATCH]Memory mapped TPR shadow featureenabling) Avi Kivity
     [not found]                     ` <46FD323C.3090905-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-09-29  3:34                       ` kvm guest memory management Dong, Eddie
     [not found]                         ` <10EA09EFD8728347A513008B6B0DA77A022AEAFE-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-09-30  8:55                           ` Avi Kivity
     [not found]                             ` <46FF647E.6080506-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-10-03 15:03                               ` Anthony Liguori [this message]
2007-10-22  8:49       ` [RFC][PATCH]Memory mapped TPR shadow feature enabling Yang, Sheng
     [not found]         ` <DB3BD37E3533EE46BED2FBA80995557F9BE17A-wq7ZOvIWXbM/UvCtAeCM4rfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-10-22  9:00           ` Avi Kivity
     [not found]             ` <471C66C1.6000508-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-10-22  9:11               ` Yang, Sheng
     [not found]                 ` <DB3BD37E3533EE46BED2FBA80995557F9BE19D-wq7ZOvIWXbM/UvCtAeCM4rfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-10-22  9:32                   ` Avi Kivity
     [not found]                     ` <471C6E14.9030502-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-10-22  9:45                       ` Yang, Sheng
     [not found]                         ` <DB3BD37E3533EE46BED2FBA80995557F9BE1B0-wq7ZOvIWXbM/UvCtAeCM4rfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-10-22  9:48                           ` Avi Kivity

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=4703AF37.7030602@us.ibm.com \
    --to=aliguori-r/jw6+rmf7hqt0dzr+alfa@public.gmane.org \
    --cc=avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org \
    --cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.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