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] [PATCH, fixed] linux/x86: use sysenter/syscall for 32-bi

To: Andi Kleen <ak@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH, fixed] linux/x86: use sysenter/syscall for 32-bit apps on 64-bit Xen
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Wed, 24 Oct 2007 15:31:12 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 24 Oct 2007 07:32:00 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200710241628.32900.ak@xxxxxxx>
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>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcgWSoaAxOOZwII9Edy0vQAX8io7RQ==
Thread-topic: [Xen-devel] [PATCH, fixed] linux/x86: use sysenter/syscall for 32-bit apps on 64-bit Xen
User-agent: Microsoft-Entourage/11.3.6.070618
On 24/10/07 15:28, "Andi Kleen" <ak@xxxxxxx> wrote:

> Perhaps pointing out the obvious; but your comment seems a little strange
> or I am misunderstanding something.
> 
> Of course does a 32bit kernel native kernel use  SYSENTER.
> 
> The only CPU with SYSCALL and no SYSENTER was AMD K6, but there SYSCALL
> was slightly different and unusable (IIRC).
> 
> So it always uses SYSENTER because it SYSCALL doesn't make sense.
> 
> But for compat tasks running on a 64bit kernel obviously SYSCALL
> has to be used and that is what the native kernel does transparently
> using the  32bit vsyscall page.

The issue here is 32-bit application on 32-bit kernel on 64-bit hypervisor.
In this configuration we cannot use SYSENTER on AMD CPUs (as we could with a
32-bit kernel on native) as we are not in legacy mode. But we could use
SYSCALL, except that the code is not there in i386 Linux (for the reason you
state above) and Jan has not seen fit to add it.

 -- Keir



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