Re: [PATCH v2] arm64: Enable KCSAN

From: Marco Elver
Date: Wed Dec 01 2021 - 05:17:54 EST


On Mon, 29 Nov 2021 at 15:46, Kefeng Wang <wangkefeng.wang@xxxxxxxxxx> wrote:
> This patch enables KCSAN for arm64, with updates to build rules
> to not use KCSAN for several incompatible compilation units.
>
> Resent GCC version(at least GCC10) made outline-atomics as the
> default option(unlike Clang), which will cause linker errors
> for kernel/kcsan/core.o.
>
> Disables the out-of-line atomics by no-outline-atomics to fix
> the linker errors.
>
> Tested selftest and kcsan_test(built with GCC11 and Clang 13),
> and all passed.
>
> Signed-off-by: Kefeng Wang <wangkefeng.wang@xxxxxxxxxx>

Acked-by: Marco Elver <elver@xxxxxxxxxx> # kernel/kcsan

However, you need to wait for Mark to respond, because he'd know best
what might be missing.
This thread might give some clues:
https://groups.google.com/g/kasan-dev/c/4ySdJfedzso/m/e4CzdfWWBQAJ
(can't find LKML copy)

Thanks,
-- Marco