|   | 
      | 
  
  
      | 
      | 
  
 
     | 
    | 
  
  
     | 
    | 
  
  
    |   | 
      | 
  
  
    | 
         
xen-devel
[Xen-devel] Re: [PATCH][RFC] Emulating real mode with x86_emulate
 
| 
To:  | 
"Anthony Liguori" <aliguori@xxxxxxxxxx> | 
 
| 
Subject:  | 
[Xen-devel] Re: [PATCH][RFC] Emulating real mode with x86_emulate | 
 
| 
From:  | 
"Kamble, Nitin A" <nitin.a.kamble@xxxxxxxxx> | 
 
| 
Date:  | 
Mon, 2 Apr 2007 11:45:25 -0700 | 
 
| 
Cc:  | 
"Yu, Wilfred" <wilfred.yu@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx,	Keir Fraser <keir@xxxxxxxxxxxxx>, "Nakajima, Jun" <jun.nakajima@xxxxxxxxx> | 
 
| 
Delivery-date:  | 
Mon, 02 Apr 2007 11:44:33 -0700 | 
 
| 
Envelope-to:  | 
www-data@xxxxxxxxxxxxxxxxxx | 
 
| 
In-reply-to:  | 
<460D8B1B.6020308@xxxxxxxxxx> | 
 
| 
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> | 
 
| 
References:  | 
<4607074E.1030807@xxxxxxxxxx>	<1175203075.27076.17.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<460C4AAE.5020707@xxxxxxxxxx>	<1175212362.27076.32.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<460C55BD.5050202@xxxxxxxxxx>	<1175216381.27076.39.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<1175221214.27076.43.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<460C8207.8000604@xxxxxxxxxx>	<1175280781.32115.13.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<460D5E34.2080803@xxxxxxxxxx>	<1175288913.32115.20.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<1175289886.32115.26.camel@xxxxxxxxxxxxxxxxxxxxxxxxxx>	<460D8B1B.6020308@xxxxxxxxxx> | 
 
| 
Sender:  | 
xen-devel-bounces@xxxxxxxxxxxxxxxxxxx | 
 
| 
Thread-index:  | 
Acd1VxOZqWssptKkTqCTeAED+Z1VpA== | 
 
| 
Thread-topic:  | 
[PATCH][RFC] Emulating real mode with x86_emulate | 
 
 
 
On Fri, 2007-03-30 at 15:11 -0700, Anthony Liguori wrote: 
 
    set_cr0 is returning 1 though which should increment eip to the next 
    instruction. 
     
    I'm a bit perplexed about my eip now and also why your eip is still 0.  
    It should be the instruction following the mov cr0. 
     
    Regards, 
     
    Anthony Liguori 
     
 
 
Hi Anthony, 
    I don't see any code doing context save/restore like vmx_world_save , vmx_world_restore in the current code for the hyperviser based emulator. 
Also the function  arch_vmx_do_resume() is called at the time of vcpu schedule, so it is not right to call the  vmx_do_emulate() from there. 
 
The code would need vmx_world_save/restore in the code path before returning to vmx_asm_vmexit_handler from vmx_vmexit_handler. 
Without that I don't see it can emulate any instructions. 
 
Thanks & Regards, 
Nitin  
Open Source Technology Center, Intel Corporation. 
------------------------------------------------------------------------- 
The mind is like a parachute; it works much better when it's open. 
 | 
 
 
 
signature.asc 
Description: This is a digitally signed message part 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
 
 |   
 
 | 
    | 
  
  
    |   | 
    |