From: Daniel Stodden Subject: Re: how page faults are handled in paravirtualized xenguests? Date: Wed, 12 Mar 2008 10:37:35 +0100 Message-ID: <1205314655.6230.43.camel@thinkpad.localdomain> References: <47D5E29E.9030706@sina.com.cn> <1205216487.31220.10.camel@thinkpad.localdomain> <1205252780.31220.74.camel@thinkpad.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <1205252780.31220.74.camel@thinkpad.localdomain> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: weiming Cc: xen-devel , tgh List-Id: xen-devel@lists.xenproject.org On Tue, 2008-03-11 at 17:28 +0100, Daniel Stodden wrote: > yes. The ring1 kernel only works if you can play some tricks on virtual > memory management in order to protect ring1 kernel memory from ring3 > user space (paging alone only distinguishes 0 from 1-3). On x86_32, =EF=BB=BFi should probably correct myself. wrong story, sorry.=20 of course, paging distingushes ring 0-2 from 3.=20 so 32-bit in 0/1/3 with segmentation protects xen from the kernel, and 32-bit paging then protects xen and the kernel from user mode.=20 64-bit paging in 0/3/3 protects xen from both kernel and user mode, but as i mentioned, you need a PT switch to keep the kernel safe.=20 maybe more than you asked for :} daniel --=20 Daniel Stodden LRR - Lehrstuhl f=C3=BCr Rechnertechnik und Rechnerorganisation Institut f=C3=BCr Informatik der TU M=C3=BCnchen D-85748 Garc= hing http://www.lrr.in.tum.de/~stodden mailto:stodden@cs.tum.edu PGP Fingerprint: F5A4 1575 4C56 E26A 0B33 3D80 457E 82AE B0D8 735B