Re: [PATCH] kvm: Disable objtool frame pointer checking for vmenter.S

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/20/20 9:17 AM, Josh Poimboeuf wrote:
> Frame pointers are completely broken by vmenter.S because it clobbers
> RBP:
> 
>   arch/x86/kvm/svm/vmenter.o: warning: objtool: __svm_vcpu_run()+0xe4: BP used as a scratch register
> 
> That's unavoidable, so just skip checking that file when frame pointers
> are configured in.
> 
> On the other hand, ORC can handle that code just fine, so leave objtool
> enabled in the !FRAME_POINTER case.
> 
> Reported-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
> Signed-off-by: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>

Acked-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx> # build-tested

Thanks.

> ---
>  arch/x86/kvm/Makefile | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/x86/kvm/Makefile b/arch/x86/kvm/Makefile
> index a789759b7261..4a3081e9f4b5 100644
> --- a/arch/x86/kvm/Makefile
> +++ b/arch/x86/kvm/Makefile
> @@ -3,6 +3,10 @@
>  ccflags-y += -Iarch/x86/kvm
>  ccflags-$(CONFIG_KVM_WERROR) += -Werror
>  
> +ifeq ($(CONFIG_FRAME_POINTER),y)
> +OBJECT_FILES_NON_STANDARD_vmenter.o := y
> +endif
> +
>  KVM := ../../../virt/kvm
>  
>  kvm-y			+= $(KVM)/kvm_main.o $(KVM)/coalesced_mmio.o \
> 


-- 
~Randy



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux