From 6e0336351ed95e2f72e396b3e1d055a8f5663542 Mon Sep 17 00:00:00 2001 From: "Liu, Jinsong" Date: Wed, 26 Sep 2012 12:12:42 +0200 Subject: x86: Implement TSC adjust feature for HVM guest IA32_TSC_ADJUST MSR is maintained separately for each logical processor. A logical processor maintains and uses the IA32_TSC_ADJUST MSR as follows: 1). On RESET, the value of the IA32_TSC_ADJUST MSR is 0; 2). If an execution of WRMSR to the IA32_TIME_STAMP_COUNTER MSR adds (or subtracts) value X from the TSC, the logical processor also adds (or subtracts) value X from the IA32_TSC_ADJUST MSR; 3). If an execution of WRMSR to the IA32_TSC_ADJUST MSR adds (or subtracts) value X from that MSR, the logical processor also adds (or subtracts) value X from the TSC. This patch provides tsc adjust support for hvm guest, with it guest OS would be happy when sync tsc. Signed-off-by: Liu, Jinsong Committed-by: Jan Beulich --- xen/include/asm-x86/hvm/vcpu.h | 1 + 1 file changed, 1 insertion(+) (limited to 'xen/include/asm-x86/hvm/vcpu.h') diff --git a/xen/include/asm-x86/hvm/vcpu.h b/xen/include/asm-x86/hvm/vcpu.h index 9d68ed226d..e8b8cd76ba 100644 --- a/xen/include/asm-x86/hvm/vcpu.h +++ b/xen/include/asm-x86/hvm/vcpu.h @@ -137,6 +137,7 @@ struct hvm_vcpu { struct hvm_vcpu_asid n1asid; u32 msr_tsc_aux; + u64 msr_tsc_adjust; /* VPMU */ struct vpmu_struct vpmu; -- cgit v1.2.3