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] Checking hypercall page existence!

To: "Jayaraman, Bhaskar" <Bhaskar.Jayaraman@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Checking hypercall page existence!
From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Date: Sun, 02 Nov 2008 08:13:46 +0000
Cc:
Delivery-date: Sun, 02 Nov 2008 01:13:56 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <F4789BF54654AC44982AC0ED2DE2E64B2CAF0F1C72@xxxxxxxxxxxxxxxxx>
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: AQHJO/oBlW020ErBRkCGeJaGjUvEEo7lgvI2gAF8pUeAAA5P1w==
Thread-topic: [Xen-devel] Checking hypercall page existence!
User-agent: Microsoft-Entourage/11.4.0.080122
Dumping the page contents and disassembling would be sensible.

 -- Keir

On 2/11/08 07:28, "Jayaraman, Bhaskar" <Bhaskar.Jayaraman@xxxxxxx> wrote:

> No Keir, VxWorks doesn't have a user, kernel context and everything runs in
> kernel mode in it. All tasks are scheduled in Ring0 on it so I'm not entirely
> sure why my hypercalls are failing, although I'm able to load the hypercall
> page. I'll try invoking a few more calls and check if all the hypercalls are
> failing. I'm hoping that if I call more hypercalls and if the hypercall page
> hasn't even loaded properly maybe I'm missing an instruction segment interrupt
> (Invalid opcode etc) as the hypercall branch is probably going to a legitimate
> instruction address for the ones I'm calling right now.
> On the other hand I was also thinking of dumping the whole 4k page laoded by
> wrmsr onto the terminal and check for hypercall opcodes within it to see if
> the page was actually loaded. If there's some other way of checking if the
> page has loaded properly, or if you think I may have to do something else to
> make the calls work please let me know.
> Bhaskar.
> ________________________________________
> From: Keir Fraser [keir.fraser@xxxxxxxxxxxxx]
> Sent: Saturday, November 01, 2008 4:40 AM
> To: Jayaraman, Bhaskar; xen-devel@xxxxxxxxxxxxxxxxxxx
> Subject: Re: [Xen-devel] Checking hypercall page existence!
> 
> You can only execute hypercalls from ring 0 (kernel context), not user
> space. Is that your problem?
> 
>  -- Keir
> 
> On 1/11/08 08:15, "Jayaraman, Bhaskar" <Bhaskar.Jayaraman@xxxxxxx> wrote:
> 
>> Hi, I've mapped hypercall pages onto a VxWorks HVM using the CPUID and WRMSR
>> instructions on a 32 bit pentium machine. However, when I'm trying to make a
>> hypercall on it the hypercall on it I'm unable to succeed and it fails. I
>> tried the HYPERVISOR_xen_version and HYPERVISOR_vm_assist hypercalls and they
>> both are returning < 0 values.
>> I was wondering whether there is any way in which I can verify whether the
>> hypercall pages have actually been mapped. I could take a dump of the pages
>> that wrmsr maps into my domain and look through it for hypercall opcodes but
>> if there is an easier way to confirm that, like a signature in the page
>> mapped, please let me know.
>> Thanks.
>> Bhaskar.
>> 
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@xxxxxxxxxxxxxxxxxxx
>> http://lists.xensource.com/xen-devel
> 
> 



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