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-users

RE: [Xen-users] VIRT to MACHINE conversion

To: "Security Initiative Team" <passrete@xxxxxxxxx>, "Ulrich Windl" <ulrich.windl@xxxxxxxxxxxxxxxxxxxx>
Subject: RE: [Xen-users] VIRT to MACHINE conversion
From: "Petersson, Mats" <Mats.Petersson@xxxxxxx>
Date: Wed, 10 Jan 2007 14:45:23 +0100
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 10 Jan 2007 05:48:36 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <883963.14342.qm@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Acc0u1HVARiXRl5nQoWYA9Lc3bouOgAAcgDA
Thread-topic: [Xen-users] VIRT to MACHINE conversion
 

> -----Original Message-----
> From: Security Initiative Team [mailto:passrete@xxxxxxxxx] 
> Sent: 10 January 2007 13:28
> To: Petersson, Mats; Ulrich Windl
> Cc: xen-users@xxxxxxxxxxxxxxxxxxx
> Subject: RE: [Xen-users] VIRT to MACHINE conversion
> 
> In the default mode of operation, doesn't Xen work without SPTs?

Xenified guests (non-HVM) do indeed write directly to the page-table via
the Hypercalls. 

> 
> The addresses entered into the PTs of the guest are actual 
> machine addresses,
> right?
> So the PTs remain a virtual-to-machine address mapping,
> so where do the (pseudo) physical addresses come into play.

That's the HVM way of working - since OS's need memory to start "at
zero", the hypervisor will have a three-level translation.
> 
> Also, when a guest domain wants to update the PT of a process,
> (say to change the permissions from read-only to writable),
> what is the exact parameter that it sends to the hypervisor --
> page frame number ?

Look at the code in xen/arch/x86/mm.c:do_mmu_update and you'll be at a
good starting point. 

--
Mats
> 
> 
> 
> "Petersson, Mats" <Mats.Petersson@xxxxxxx> wrote:
> 
>       > > I'm confused about the relation between 
>       > > virt and phy addresses in a guest domain?
>       > > What is the co-relation between the two?
>       > > 
>       
>       The guest will manage it's own virtual memory mappings. 
> However, those
>       are guest physical addresses, so the guest will think 
> that it's got
>       0..256M address range, whilst the machine physical 
> address is, say,
>       256M..512M. 
>       
>       So there is, essentially, a second level of 
> indirection. This is managed
>       by the shadow page table code in Xen - this works in 
> essence by having
>       two different page-tables, one that the guest updates, 
> one that is
>       maintained by the SPT code. The SPT table will be the 
> one that the
>       processor actually uses. 
>       
>       
> 
> ________________________________
> 
> Access over 1 million songs - Yahoo! Music Unlimited. 
> <http://pa.yahoo.com/*http://us.rd.yahoo.com/evt=36035/*http:/
> /music.yahoo.com/unlimited/> 
> 



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

<Prev in Thread] Current Thread [Next in Thread>