Skip to content

Commit 480c240

Browse files
Peter Zijlstragregkh
authored andcommitted
x86: Increase exception stack sizes
[ Upstream commit 7fae4c2 ] It turns out that a single page of stack is trivial to overflow with all the tracing gunk enabled. Raise the exception stacks to 2 pages, which is still half the interrupt stacks, which are at 4 pages. Reported-by: Michael Wang <yun.wang@linux.alibaba.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lkml.kernel.org/r/YUIO9Ye98S5Eb68w@hirez.programming.kicks-ass.net Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 91b9c23 commit 480c240

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/x86/include/asm/page_64_types.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
#define THREAD_SIZE_ORDER (2 + KASAN_STACK_ORDER)
1616
#define THREAD_SIZE (PAGE_SIZE << THREAD_SIZE_ORDER)
1717

18-
#define EXCEPTION_STACK_ORDER (0 + KASAN_STACK_ORDER)
18+
#define EXCEPTION_STACK_ORDER (1 + KASAN_STACK_ORDER)
1919
#define EXCEPTION_STKSZ (PAGE_SIZE << EXCEPTION_STACK_ORDER)
2020

2121
#define IRQ_STACK_ORDER (2 + KASAN_STACK_ORDER)

0 commit comments

Comments
 (0)