diff options
author | Peter Zijlstra <peterz@infradead.org> | 2019-11-20 15:02:26 +0100 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2019-11-21 19:37:44 +0100 |
commit | 895429076512e9d1cf5428181076299c90713159 (patch) | |
tree | 7eff4b7910d6460b397c3b1601dd532536321aab /tools/testing | |
parent | x86/entry/32: Unwind the ESPFIX stack earlier on exception entry (diff) | |
download | linux-895429076512e9d1cf5428181076299c90713159.tar.xz linux-895429076512e9d1cf5428181076299c90713159.zip |
x86/entry/32: Fix NMI vs ESPFIX
When the NMI lands on an ESPFIX_SS, we are on the entry stack and must
swizzle, otherwise we'll run do_nmi() on the entry stack, which is
BAD.
Also, similar to the normal exception path, we need to correct the
ESPFIX magic before leaving the entry stack, otherwise pt_regs will
present a non-flat stack pointer.
Tested by running sigreturn_32 concurrent with perf-record.
Fixes: e5862d0515ad ("x86/entry/32: Leave the kernel via trampoline stack")
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Andy Lutomirski <luto@kernel.org>
Cc: stable@kernel.org
Diffstat (limited to 'tools/testing')
0 files changed, 0 insertions, 0 deletions