diff options
author | Andy Lutomirski <luto@kernel.org> | 2015-10-05 20:48:02 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-10-09 03:41:07 -0400 |
commit | e62a254a1f93fcc7299497a5c7231639400b8c3c (patch) | |
tree | c06f2ea51c67c3052886ea14f2418900a2b0478a | |
parent | 8242c6c84a644e5f0f721e4ae2bd542f640c89f9 (diff) |
x86/entry/64/compat: Disable SYSENTER and SYSCALL32 entries
We've disabled the vDSO helpers to call them, so turn off the
entries entirely (temporarily) in preparation for cleaning them
up.
Signed-off-by: Andy Lutomirski <luto@kernel.org>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Link: http://lkml.kernel.org/r/8d6e84bf651519289dc532dcc230adfabbd2a3eb.1444091584.git.luto@kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r-- | arch/x86/entry/entry_64_compat.S | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/x86/entry/entry_64_compat.S b/arch/x86/entry/entry_64_compat.S index bc678f0c3c91..06a8966415f9 100644 --- a/arch/x86/entry/entry_64_compat.S +++ b/arch/x86/entry/entry_64_compat.S | |||
@@ -103,6 +103,14 @@ ENTRY(entry_SYSENTER_compat) | |||
103 | jnz sysenter_fix_flags | 103 | jnz sysenter_fix_flags |
104 | sysenter_flags_fixed: | 104 | sysenter_flags_fixed: |
105 | 105 | ||
106 | /* Temporary: SYSENTER is disabled. */ | ||
107 | #ifdef CONFIG_CONTEXT_TRACKING | ||
108 | call enter_from_user_mode | ||
109 | #endif | ||
110 | ENABLE_INTERRUPTS(CLBR_NONE) | ||
111 | movl $11, %edi | ||
112 | call do_exit | ||
113 | |||
106 | /* | 114 | /* |
107 | * Re-enable interrupts. IRQ tracing already thinks that IRQs are | 115 | * Re-enable interrupts. IRQ tracing already thinks that IRQs are |
108 | * on (since we treat user mode as having IRQs on), and the | 116 | * on (since we treat user mode as having IRQs on), and the |
@@ -324,6 +332,11 @@ ENTRY(entry_SYSCALL_compat) | |||
324 | * it is too small to ever cause noticeable irq latency. | 332 | * it is too small to ever cause noticeable irq latency. |
325 | */ | 333 | */ |
326 | SWAPGS_UNSAFE_STACK | 334 | SWAPGS_UNSAFE_STACK |
335 | |||
336 | /* Temporary: SYSCALL32 is disabled. */ | ||
337 | movl $-ENOSYS, %eax | ||
338 | USERGS_SYSRET32 | ||
339 | |||
327 | movl %esp, %r8d | 340 | movl %esp, %r8d |
328 | movq PER_CPU_VAR(cpu_current_top_of_stack), %rsp | 341 | movq PER_CPU_VAR(cpu_current_top_of_stack), %rsp |
329 | ENABLE_INTERRUPTS(CLBR_NONE) | 342 | ENABLE_INTERRUPTS(CLBR_NONE) |