x86/entry: Increase entry_stack size to a full page
authorPeter Zijlstra <peterz@infradead.org>
Wed, 17 Jun 2020 16:25:57 +0000 (18:25 +0200)
committerPeter Zijlstra <peterz@infradead.org>
Thu, 25 Jun 2020 11:45:40 +0000 (13:45 +0200)
Marco crashed in bad_iret with a Clang11/KCSAN build due to
overflowing the stack. Now that we run C code on it, expand it to a
full page.

Suggested-by: Andy Lutomirski <luto@amacapital.net>
Reported-by: Marco Elver <elver@google.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Lai Jiangshan <jiangshanlai@gmail.com>
Tested-by: Marco Elver <elver@google.com>
Link: https://lkml.kernel.org/r/20200618144801.819246178@infradead.org
arch/x86/include/asm/processor.h

index 42cd333616c487b5730bfd909660784f0f231981..03b7c4ca425a620880719e97bd2a6d2b09857730 100644 (file)
@@ -370,7 +370,7 @@ struct x86_hw_tss {
 #define IO_BITMAP_OFFSET_INVALID       (__KERNEL_TSS_LIMIT + 1)
 
 struct entry_stack {
-       unsigned long           words[64];
+       char    stack[PAGE_SIZE];
 };
 
 struct entry_stack_page {