]> www.infradead.org Git - users/dwmw2/linux.git/commit
KVM: Move KVM context switch into own function
authorAndi Kleen <ak@linux.intel.com>
Wed, 20 Oct 2010 15:56:17 +0000 (17:56 +0200)
committerMarcelo Tosatti <mtosatti@redhat.com>
Thu, 21 Oct 2010 16:43:31 +0000 (14:43 -0200)
commitcea15c24ca3989088c29d0cb9efad9da57176a48
treeae7af979d33e184ae6de7bab94c66076363cdef3
parentd2119ad3a524821e7e0260b94d2d25acedd52a5e
KVM: Move KVM context switch into own function

gcc 4.5 with some special options is able to duplicate the VMX
context switch asm in vmx_vcpu_run(). This results in a compile error
because the inline asm sequence uses an on local label. The non local
label is needed because other code wants to set up the return address.

This patch moves the asm code into an own function and marks
that explicitely noinline to avoid this problem.

Better would be probably to just move it into an .S file.

The diff looks worse than the change really is, it's all just
code movement and no logic change.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/x86/kvm/vmx.c