#include <asm/processor-flags.h>
#include <asm/ftrace.h>
#include <asm/irq_vectors.h>
+#include <asm/cpufeature.h>
/* Avoid __ASSEMBLER__'ifying <linux/audit.h> just for this. */
#include <linux/elf-em.h>
CFI_SIGNAL_FRAME
CFI_DEF_CFA esp, 0
CFI_REGISTER esp, ebp
- movl SYSENTER_stack_sp0(%esp),%esp
+ movl TSS_sysenter_sp0(%esp),%esp
sysenter_past_esp:
/*
* Interrupts are disabled here, but we can't trace it until
RING0_INT_FRAME
pushl $0
CFI_ADJUST_CFA_OFFSET 4
+#ifdef CONFIG_X86_INVD_BUG
+ /* AMD 486 bug: invd from userspace calls exception 19 instead of #GP */
+661: pushl $do_general_protection
+662:
+.section .altinstructions,"a"
+ .balign 4
+ .long 661b
+ .long 663f
+ .byte X86_FEATURE_XMM
+ .byte 662b-661b
+ .byte 664f-663f
+.previous
+.section .altinstr_replacement,"ax"
+663: pushl $do_simd_coprocessor_error
+664:
+.previous
+#else
pushl $do_simd_coprocessor_error
+#endif
CFI_ADJUST_CFA_OFFSET 4
jmp error_code
CFI_ENDPROC
CFI_ENDPROC
END(alignment_check)
-#ifdef CONFIG_KDB
-
-ENTRY(kdb_call)
- RING0_INT_FRAME
- pushl %eax # save orig EAX
- CFI_ADJUST_CFA_OFFSET 4
- SAVE_ALL
- movl %esp,%ecx # struct pt_regs
- movl $0,%edx # error_code
- movl $1,%eax # KDB_REASON_ENTER
- call kdb
- jmp restore_all
- CFI_ENDPROC
-
-#ifdef CONFIG_SMP
-BUILD_INTERRUPT(kdb_interrupt,KDB_VECTOR)
-#endif /* CONFIG_SMP */
-
-#endif /* CONFIG_KDB */
-
ENTRY(divide_error)
RING0_INT_FRAME
pushl $0 # no error code
CFI_ENDPROC
ENDPROC(kernel_thread_helper)
-#ifdef CONFIG_PARAVIRT_XEN
+#ifdef CONFIG_XEN
/* Xen doesn't set %esp to be precisely what the normal sysenter
entrypoint expects, so fix it up before using the normal path. */
ENTRY(xen_sysenter_target)
.previous
ENDPROC(xen_failsafe_callback)
-#endif /* CONFIG_PARAVIRT_XEN */
+#endif /* CONFIG_XEN */
#ifdef CONFIG_FUNCTION_TRACER
#ifdef CONFIG_DYNAMIC_FTRACE
* that sets up the real kernel stack. Check here, since we can't
* allow the wrong stack to be used.
*
- * "SYSENTER_stack_sp0+12" is because the NMI/debug handler will have
+ * "TSS_sysenter_sp0+12" is because the NMI/debug handler will have
* already pushed 3 words if it hits on the sysenter instruction:
* eflags, cs and eip.
*
cmpw $__KERNEL_CS, 4(%esp)
jne \ok
\label:
- movl SYSENTER_stack_sp0 + \offset(%esp), %esp
+ movl TSS_sysenter_sp0 + \offset(%esp), %esp
CFI_DEF_CFA esp, 0
CFI_UNDEFINED eip
pushfl