All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] KVM: x86: Use native_store_idt() instead of kvm_get_idt()
@ 2010-03-05  4:11 Wei Yongjun
  2010-03-15  7:13 ` Marcelo Tosatti
  0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2010-03-05  4:11 UTC (permalink / raw)
  To: kvm; +Cc: Avi Kivity

This patch use generic linux function native_store_idt()
instead of kvm_get_idt(), and also removed the useless
function kvm_get_idt().

Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com>
---
 arch/x86/include/asm/kvm_host.h |    5 -----
 arch/x86/kvm/vmx.c              |    2 +-
 2 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index ec891a2..ea1b6c6 100644
--- a/arch/x86/include/asm/kvm_host.h
+++ b/arch/x86/include/asm/kvm_host.h
@@ -716,11 +716,6 @@ static inline void kvm_load_ldt(u16 sel)
 	asm("lldt %0" : : "rm"(sel));
 }
 
-static inline void kvm_get_idt(struct desc_ptr *table)
-{
-	asm("sidt %0" : "=m"(*table));
-}
-
 #ifdef CONFIG_X86_64
 static inline unsigned long read_msr(unsigned long msr)
 {
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index ae3217d..a08929a 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2445,7 +2445,7 @@ static int vmx_vcpu_setup(struct vcpu_vmx *vmx)
 
 	vmcs_write16(HOST_TR_SELECTOR, GDT_ENTRY_TSS*8);  /* 22.2.4 */
 
-	kvm_get_idt(&dt);
+	native_store_idt(&dt);
 	vmcs_writel(HOST_IDTR_BASE, dt.address);   /* 22.2.4 */
 
 	asm("mov $.Lkvm_vmx_return, %0" : "=r"(kvm_vmx_return));
-- 
1.6.3.3



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] KVM: x86: Use native_store_idt() instead of kvm_get_idt()
  2010-03-05  4:11 [PATCH] KVM: x86: Use native_store_idt() instead of kvm_get_idt() Wei Yongjun
@ 2010-03-15  7:13 ` Marcelo Tosatti
  0 siblings, 0 replies; 2+ messages in thread
From: Marcelo Tosatti @ 2010-03-15  7:13 UTC (permalink / raw)
  To: Wei Yongjun; +Cc: kvm, Avi Kivity

On Fri, Mar 05, 2010 at 12:11:48PM +0800, Wei Yongjun wrote:
> This patch use generic linux function native_store_idt()
> instead of kvm_get_idt(), and also removed the useless
> function kvm_get_idt().
> 
> Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com>
> ---
>  arch/x86/include/asm/kvm_host.h |    5 -----
>  arch/x86/kvm/vmx.c              |    2 +-
>  2 files changed, 1 insertions(+), 6 deletions(-)

Applied, thanks.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-03-15  8:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-05  4:11 [PATCH] KVM: x86: Use native_store_idt() instead of kvm_get_idt() Wei Yongjun
2010-03-15  7:13 ` Marcelo Tosatti

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.