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] Native hypercall basics using int 82

To: hnrkssn hnrkssn <hnrkssn@xxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Native hypercall basics using int 82
From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Date: Tue, 16 Dec 2008 08:47:39 +0000
Cc:
Delivery-date: Tue, 16 Dec 2008 00:47:51 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <6a3ccf200812160039g55343adn750be651e432d4a5@xxxxxxxxxxxxxx>
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AclfWvNHAAlpZbNrokq+CRSLQ9T8Ow==
Thread-topic: [Xen-devel] Native hypercall basics using int 82
User-agent: Microsoft-Entourage/12.14.0.081024
On 16/12/2008 08:39, "hnrkssn hnrkssn" <hnrkssn@xxxxxxxxx> wrote:

> I'm trying to detect if I'm running as a guest in XEN hypervisor using a
> simple hypercall like __HYPERVISOR_xen_version with the XENVER_extraversion
> option.
> I cannot use any of the API functions for this so I'm trying to setup the
> required registers and call int 82 myself.
> This is what I do and unfortunately, it generates an exception 0xd when
> executing INT 82.
> 
> Reading the source, I think I've figured out that I should put my arguments in
> a hypercall struct shown below. I might be wrong then.

See tools/misc/xen-detect.c for a nice approach that even works from user
space.

 -- Keir



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