]> git.baikalelectronics.ru Git - kernel.git/commit
x86/int3: Avoid atomic instrumentation
authorPeter Zijlstra <peterz@infradead.org>
Fri, 24 Jan 2020 21:08:45 +0000 (22:08 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 11 Jun 2020 13:14:53 +0000 (15:14 +0200)
commitf1bf0c53168a15293b039d94e2d87a7e013d7507
treed233031a2e6ab642f4d7a7c9ddf9d10f5388323d
parent42a515fefd627e89b418b3b28a995f02f80e4b07
x86/int3: Avoid atomic instrumentation

Use arch_atomic_*() and __READ_ONCE() to ensure nothing untoward
creeps in and ruins things.

That is; this is the INT3 text poke handler, strictly limit the code
that runs in it, lest it inadvertenly hits yet another INT3.

Reported-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org>
Reviewed-by: Alexandre Chartre <alexandre.chartre@oracle.com>
Acked-by: Andy Lutomirski <luto@kernel.org>
Link: https://lkml.kernel.org/r/20200505135313.517429268@linutronix.de
arch/x86/kernel/alternative.c