aboutsummaryrefslogtreecommitdiffstats
path: root/xen/include/asm-x86/hvm/vmx
diff options
context:
space:
mode:
authorYang Zhang <yang.z.zhang@Intel.com>2013-08-22 10:59:01 +0200
committerJan Beulich <jbeulich@suse.com>2013-08-22 10:59:01 +0200
commit84e6af58707520baf59c1c86c29237419e439afb (patch)
tree7895c5efbad165a8424933af8ff93a6d187a3c05 /xen/include/asm-x86/hvm/vmx
parent375a1035002fb257087756a86e6caeda649fc0f1 (diff)
downloadxen-84e6af58707520baf59c1c86c29237419e439afb.tar.gz
xen-84e6af58707520baf59c1c86c29237419e439afb.tar.bz2
xen-84e6af58707520baf59c1c86c29237419e439afb.zip
Nested VMX: Update APIC-v(RVI/SVI) when vmexit to L1
If enabling APIC-v, all interrupts to L1 are delivered through APIC-v. But when L2 is running, external interrupt will casue L1 vmexit with reason external interrupt. Then L1 will pick up the interrupt through vmcs12. when L1 ack the interrupt, since the APIC-v is enabled when L1 is running, so APIC-v hardware still will do vEOI updating. The problem is that the interrupt is delivered not through APIC-v hardware, this means SVI/RVI/vPPR are not setting, but hardware required them when doing vEOI updating. The solution is that, when L1 tried to pick up the interrupt from vmcs12, then hypervisor will help to update the SVI/RVI/vPPR to make sure the following vEOI updating and vPPR updating corrently. Also, since interrupt is delivered through vmcs12, so APIC-v hardware will not cleare vIRR and hypervisor need to clear it before L1 running. Signed-off-by: Yang Zhang <yang.z.zhang@Intel.com> Acked-by: "Dong, Eddie" <eddie.dong@intel.com>
Diffstat (limited to 'xen/include/asm-x86/hvm/vmx')
-rw-r--r--xen/include/asm-x86/hvm/vmx/vmx.h2
-rw-r--r--xen/include/asm-x86/hvm/vmx/vvmx.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/xen/include/asm-x86/hvm/vmx/vmx.h b/xen/include/asm-x86/hvm/vmx/vmx.h
index c33b9f9a7e..f4d759bd5a 100644
--- a/xen/include/asm-x86/hvm/vmx/vmx.h
+++ b/xen/include/asm-x86/hvm/vmx/vmx.h
@@ -448,7 +448,7 @@ static inline int __vmxon(u64 addr)
void vmx_get_segment_register(struct vcpu *, enum x86_segment,
struct segment_register *);
-void vmx_inject_extint(int trap);
+void vmx_inject_extint(int trap, uint8_t source);
void vmx_inject_nmi(void);
int ept_p2m_init(struct p2m_domain *p2m);
diff --git a/xen/include/asm-x86/hvm/vmx/vvmx.h b/xen/include/asm-x86/hvm/vmx/vvmx.h
index 3874525c1a..848be75796 100644
--- a/xen/include/asm-x86/hvm/vmx/vvmx.h
+++ b/xen/include/asm-x86/hvm/vmx/vvmx.h
@@ -36,6 +36,7 @@ struct nestedvmx {
struct {
unsigned long intr_info;
u32 error_code;
+ u8 source;
} intr;
struct {
bool_t enabled;