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-ia64-devel

Re: [Xen-ia64-devel] Faulty protection key handling

To: Tristan Gingold <tgingold@xxxxxxx>
Subject: Re: [Xen-ia64-devel] Faulty protection key handling
From: Jürgen Groß <juergen.gross@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 30 Apr 2007 07:38:44 +0200
Cc: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Sun, 29 Apr 2007 22:37:07 -0700
Domainkey-signature: s=s768; d=fujitsu-siemens.com; c=nofws; q=dns; b=tc6gILBEjxvLMpiJYvTOFrZGGNB62/8jA4Lpouv4tDII6UYNQ22fqmqrgss4oMd0hmzPtOrxhTLpWc3/PIFXJSveCkGszJRSg8UgDreswrgAZ83D2GdDNsA97PMVfkIc;
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20070428133301.GA2510@saphi>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: Fujitsu Siemens Computers
References: <200704251536.20806.dietmar.hahn@xxxxxxxxxxxxxxxxxxx> <20070426054120.GA2497@saphi> <4630472F.5020003@xxxxxxxxxxxxxxxxxxx> <20070426190821.GA2497@saphi> <20070426191205.GB2497@saphi> <46318424.9010103@xxxxxxxxxxxxxxxxxxx> <20070428133301.GA2510@saphi>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Icedove 1.5.0.10 (X11/20070328)
Tristan Gingold wrote:
>> For PV this is not completely true. If an OS uses PKRs, it has the same
>> problem as the hypervisor: one PKR with a specific value must always be 
>> loaded
>> for interrupt handling. I would see no problem to use the same PKR and PK
>> value as the hypervisor (PKR 0 with PK value 0, rwx allowed).
>> This would eliminate the restriction to 15 PKRs as well.
> Using this mechanism if fine for PV and should be very easy to implement.
> 
> But this implementation can't be merged with VTI.  This is a drawback, 
> although
> being acceptable IMHO.

Are you sure?
VTI and PV implementation will both need a PKR for hypervisor.
PV could know about this PKR and it's value, so PV would use only 15 other
PKRs.
VTI will use one PKR for the trap vector. The hypervisor should be able to
detect this special PKR and remember the PK value. In the PKR emulation PKR 0
and the VTI special PKR could be swapped, as well as the VTI PK value and
PK value 0.

Example:
VTI domain uses PKR 3 with value 123 for its trap vector.
If VTI domain accesses PKR 3, real PKR 0 is used, VTI access to PKR 0 will use
real PKR 3.
Real PK value 0 is presented as PKR value 123 to VTI domain, while real PK
value 123 is presented as 0.

PV domain could be handled in the same way, but a "clever" PV would use PKR 0
with PK value 0 for the trap vector, so the hypervisor would only do a swap of
identical values.

Juergen

-- 
Juergen Gross                             Principal Developer
IP SW OS6                      Telephone: +49 (0) 89 636 47950
Fujitsu Siemens Computers         e-mail: juergen.gross@xxxxxxxxxxxxxxxxxxx
Otto-Hahn-Ring 6                Internet: www.fujitsu-siemens.com
D-81739 Muenchen         Company details: www.fujitsu-siemens.com/imprint.html

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