WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] page table question!

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] page table question!
From: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
Date: Thu, 14 Jun 2007 10:51:50 +0100
Cc: "Petersson, Mats" <Mats.Petersson@xxxxxxx>, MT Rezaie <mmrezaie@xxxxxxxxx>
Delivery-date: Thu, 14 Jun 2007 02:49:52 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <46710007.3030200@xxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <907625E08839C4409CE5768403633E0B02561E10@xxxxxxxxxxxxxxxxx> <46710007.3030200@xxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.6
> I try to read the paging part code of xen-3.1.0, and I am confused about
> the " compat_machine_to_phys_mapping" ,what does xen do with the
> "CONFIG_COMPAT",and what are the differences between the
> "machine_to_phys_mapping" and the "compat_machine_to_phys_mapping"?

Compat-mode guests are 32-bit PAE guests running on a 64-bit hypervisor.  
Certain Xen API data structures need to be translated for compat-mode guests 
to access them; I guess the M2P mapping must be one of them but it's not 
immediately obvious to me what the differences would be.

For things like the start info / shared info page, which will also be 
different for compat-mode guests, it's more obvious since at the least there 
are probably some fields that are 64-bit or 32-bit depending on the guest 
mode...

Cheers,
Mark

> Could you help me
> Thanks in advance
>
> Petersson, Mats 写道:
> >> -----Original Message-----
> >> From: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
> >> [mailto:xen-devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of MT Rezaie
> >> Sent: 13 June 2007 15:55
> >> To: xen-devel@xxxxxxxxxxxxxxxxxxx
> >> Subject: [Xen-devel] page table question!
> >>
> >> I want to know any difference between writing, reading and shadow page
> >> table (for example performance).
> >
> > Not sure exactly what you're asking for: are you asking about "writable"
> > and "non-writable" page-table vs. shadow-page-table?
> >
> > I believe "writable" page-table means that the guest is able to write
> > DIRECTLY to the lower level(s) of the page-table, and as such, we
> > "trust" the guest to do this correctly (and not map in stuff that
> > doesn't belong to the guest). I believe this mode isn't normally used by
> > Xen guests. This mode relies on the guest to correctly translate the
> > guest-physical address to a machine physical address.
> >
> > Non-writable page-tables are mapped "read-only" throughout the entire
> > page-table, and when a write occurs, the page-table is updated via the
> > emulation of the instruction in the hypervisor. The hypervisor can check
> > that the machine physical address is correct for the particular guest.
> >
> > As of currently, Shadow-mode is only used for HVM (fully virtualized)
> > domains. In this case, the guest has a "dummy" page-table that is not
> > used by the processor for any memory accesses, instead a "shadow" (copy)
> > of the guest's page-table is used. The shadow page-table is used by the
> > processor. To make updates to the page-table appear in the
> > shadow-page-table, the hypervisor is making sure that the
> > guest-page-table is read-only, and when the guest writes to the
> > page-table, we reproduce the write [with modification to reflect the
> > difference between guest physical and machine physical address].
> >
> > --
> > Mats
> >
> >> I am thankful for any help or resource for that.
> >>
> >> --
> >> Best Regards
> >> Mohamad Taghi Mir Mohamad Rezaie
> >>
> >> Iran University of Science and Technology
> >> Department of Computer Science & Engineering
> >> System Software Group
> >>
> >> _______________________________________________
> >> Xen-devel mailing list
> >> Xen-devel@xxxxxxxxxxxxxxxxxxx
> >> http://lists.xensource.com/xen-devel
> >
> > _______________________________________________
> > Xen-devel mailing list
> > Xen-devel@xxxxxxxxxxxxxxxxxxx
> > http://lists.xensource.com/xen-devel
> >
> >
> > .
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel



-- 
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel