x86/doublefault: Remove memmove() call
authorPeter Zijlstra <peterz@infradead.org>
Thu, 20 Feb 2020 12:17:27 +0000 (13:17 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 11 Jun 2020 13:14:34 +0000 (15:14 +0200)
commite9660391d0ebd174b169af3d6de680c2f836027c
tree807efa70f0ff4dfaf303fe5d9d2358d2f93b4a3b
parent24ae0c91cbc57c2deb0401bd653453a508acdcee
x86/doublefault: Remove memmove() call

Use of memmove() in #DF is problematic considered tracing and other
instrumentation.

Remove the memmove() call and simply write out what needs doing; this
even clarifies the code, win-win! The code copies from the espfix64
stack to the normal task stack, there is no possible way for that to
overlap.

Survives selftests/x86, specifically sigreturn_64.

Suggested-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Alexandre Chartre <alexandre.chartre@oracle.com>
Acked-by: Andy Lutomirski <luto@kernel.org>
Link: https://lkml.kernel.org/r/20200505134058.863038566@linutronix.de
arch/x86/kernel/traps.c