]> git.baikalelectronics.ru Git - kernel.git/commit
kcsan, kbuild: Add option for barrier instrumentation only
authorMarco Elver <elver@google.com>
Tue, 30 Nov 2021 11:44:14 +0000 (12:44 +0100)
committerPaul E. McKenney <paulmck@kernel.org>
Fri, 10 Dec 2021 00:42:26 +0000 (16:42 -0800)
commitf27ff4fdcfe5918ceaaf564dec2e0fc5d24a61bc
tree44a91fc9e807de5a04197b68565ea4416898336d
parentc13a314f9b5a99de6adeecc75dfb8f00b2e99921
kcsan, kbuild: Add option for barrier instrumentation only

Source files that disable KCSAN via KCSAN_SANITIZE := n, remove all
instrumentation, including explicit barrier instrumentation. With
instrumentation for memory barriers, in few places it is required to
enable just the explicit instrumentation for memory barriers to avoid
false positives.

Providing the Makefile variable KCSAN_INSTRUMENT_BARRIERS_obj.o or
KCSAN_INSTRUMENT_BARRIERS (for all files) set to 'y' only enables the
explicit barrier instrumentation.

Signed-off-by: Marco Elver <elver@google.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
scripts/Makefile.lib