From 18b13e5457041429af3974afd52f647c3a5465dd Mon Sep 17 00:00:00 2001 From: Eduardo Habkost Date: Tue, 19 Aug 2008 20:00:08 -0300 Subject: [PATCH] KVM: Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot vmlinux.lds expects the fixup code to be on a section named .fixup. The .text.fixup section is not mentioned on vmlinux.lds, and is included on the resulting vmlinux (just after .text) only because of ld heuristics on placing orphan sections. However, placing .text.fixup outside .text breaks the definition of _etext, making it exclude the .text.fixup contents. That makes .text.fixup be ignored by the kernel initialization code that needs to know about section locations, such as the code setting page protection bits. Signed-off-by: Eduardo Habkost Signed-off-by: Avi Kivity --- include/asm-x86/kvm_host.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/asm-x86/kvm_host.h b/include/asm-x86/kvm_host.h index 0f3c53114614..c2e34c275900 100644 --- a/include/asm-x86/kvm_host.h +++ b/include/asm-x86/kvm_host.h @@ -722,7 +722,7 @@ asmlinkage void kvm_handle_fault_on_reboot(void); #define __kvm_handle_fault_on_reboot(insn) \ "666: " insn "\n\t" \ - ".pushsection .text.fixup, \"ax\" \n" \ + ".pushsection .fixup, \"ax\" \n" \ "667: \n\t" \ KVM_EX_PUSH " $666b \n\t" \ "jmp kvm_handle_fault_on_reboot \n\t" \ -- 2.11.0