|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PATCH 1/4] HVM save/restore clean up: fix vmcs padding issu
[PATCH 1/4] HVM save/restore clean up: fix vmcs padding issues
Signed-off-by: Zhai Edwin <edwin.zhai@xxxxxxxxx>
hvmcpu_context is not well padded in previous patch, this patch fix it.
diff -r e2539ab3580a xen/include/public/arch-x86/xen.h
--- a/xen/include/public/arch-x86/xen.h Thu Jan 18 18:54:28 2007 +0000
+++ b/xen/include/public/arch-x86/xen.h Fri Jan 19 18:33:01 2007 +0800
@@ -118,56 +118,60 @@ struct vmcs_data {
uint64_t cr0;
uint64_t cr3; /* page table directory */
uint64_t cr4;
+ uint64_t idtr_base;
+ uint64_t gdtr_base;
+ uint64_t cs_base;
+ uint64_t ds_base;
+ uint64_t es_base;
+ uint64_t ss_base;
+ uint64_t fs_base;
+ uint64_t gs_base;
+ uint64_t tr_base;
+ uint64_t ldtr_base;
+ uint64_t sysenter_esp;
+ uint64_t sysenter_eip;
+
+ /* msr for em64t */
+ uint64_t shadow_gs;
+ uint64_t flags;
+
+ /* same size as VMX_MSR_COUNT */
+ uint64_t msr_items[6];
+ uint64_t vmxassist_enabled;
+
uint32_t idtr_limit; /* idt */
- uint64_t idtr_base;
uint32_t gdtr_limit; /* gdt */
- uint64_t gdtr_base;
uint32_t cs_sel; /* cs selector */
uint32_t cs_limit;
- uint64_t cs_base;
uint32_t cs_arbytes;
uint32_t ds_sel; /* ds selector */
uint32_t ds_limit;
- uint64_t ds_base;
uint32_t ds_arbytes;
uint32_t es_sel; /* es selector */
uint32_t es_limit;
- uint64_t es_base;
uint32_t es_arbytes;
uint32_t ss_sel; /* ss selector */
uint32_t ss_limit;
- uint64_t ss_base;
uint32_t ss_arbytes;
uint32_t fs_sel; /* fs selector */
uint32_t fs_limit;
- uint64_t fs_base;
uint32_t fs_arbytes;
uint32_t gs_sel; /* gs selector */
uint32_t gs_limit;
- uint64_t gs_base;
uint32_t gs_arbytes;
uint32_t tr_sel; /* task selector */
uint32_t tr_limit;
- uint64_t tr_base;
uint32_t tr_arbytes;
uint32_t ldtr_sel; /* ldtr selector */
uint32_t ldtr_limit;
- uint64_t ldtr_base;
uint32_t ldtr_arbytes;
uint32_t sysenter_cs;
- uint64_t sysenter_esp;
- uint64_t sysenter_eip;
- /* msr for em64t */
- uint64_t shadow_gs;
- uint64_t flags;
- /* same size as VMX_MSR_COUNT */
- uint64_t msr_items[6];
- uint64_t vmxassist_enabled;
+ uint32_t _pad;
};
typedef struct vmcs_data vmcs_data_t;
struct hvmcpu_context {
- uint32_t valid;
+ uint64_t valid;
struct vmcs_data data;
uint64_t gtime;
};
@@ -189,6 +193,7 @@ struct vcpu_guest_context {
#define VGCF_failsafe_disables_events (1<<_VGCF_failsafe_disables_events)
#define _VGCF_syscall_disables_events 4
#define VGCF_syscall_disables_events (1<<_VGCF_syscall_disables_events)
+ struct hvmcpu_context hvmcpu_ctxt; /* whole vmcs region */
unsigned long flags; /* VGCF_* flags */
struct cpu_user_regs user_regs; /* User-level CPU registers */
struct trap_info trap_ctxt[256]; /* Virtual IDT */
@@ -218,7 +223,6 @@ struct vcpu_guest_context {
#endif
#endif
unsigned long vm_assist; /* VMASST_TYPE_* bitmap */
- struct hvmcpu_context hvmcpu_ctxt; /* whole vmcs region */
#ifdef __x86_64__
/* Segment base addresses. */
uint64_t fs_base;
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [PATCH 1/4] HVM save/restore clean up: fix vmcs padding issues,
Zhai, Edwin <=
|
|
|
|
|