linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/5] powerpc: Add KCSAN support
@ 2023-02-01  4:34 Rohan McLure
  2023-02-01  4:34 ` [PATCH v2 1/5] powerpc: kcsan: Add exclusions from instrumentation Rohan McLure
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Rohan McLure @ 2023-02-01  4:34 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Rohan McLure, npiggin

Add Kernel Concurrency Sanitiser support for powerpc. Doing so involves
exclusion of a number of compilation units from instrumentation, as was
done with KASAN.

KCSAN uses watchpoints on memory accesses to enforce the semantics of
the Linux kernel memory model, notifying the user of observed data races
which have not been declared to be intended in source through the
data_race() macro, in order to remove false positives.

A number of such race conditions are identified. This patch series
provides support for the instrumentation, with bug fixes as well as
removal of false positives to be issued in future patches.

v2: Implement __smp_mb() in terms of __mb() to avoid multiple calls to
kcsan_mb().

v1: https://lore.kernel.org/linuxppc-dev/20230131234859.1275125-1-rmclure@linux.ibm.com/

Rohan McLure (5):
  powerpc: kcsan: Add exclusions from instrumentation
  powerpc: kcsan: Exclude udelay to prevent recursive instrumentation
  powerpc: kcsan: Memory barriers semantics
  powerpc: kcsan: Prevent recursive instrumentation with IRQ
    save/restores
  powerpc: kcsan: Add KCSAN Support

 arch/powerpc/Kconfig               |  1 +
 arch/powerpc/include/asm/barrier.h | 12 ++++++------
 arch/powerpc/kernel/Makefile       | 10 ++++++++++
 arch/powerpc/kernel/irq_64.c       |  6 +++---
 arch/powerpc/kernel/time.c         |  4 ++--
 arch/powerpc/kernel/trace/Makefile |  1 +
 arch/powerpc/kernel/vdso/Makefile  |  1 +
 arch/powerpc/lib/Makefile          |  2 ++
 arch/powerpc/purgatory/Makefile    |  1 +
 arch/powerpc/xmon/Makefile         |  1 +
 10 files changed, 28 insertions(+), 11 deletions(-)

-- 
2.37.2


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2023-02-04 12:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-01  4:34 [PATCH v2 0/5] powerpc: Add KCSAN support Rohan McLure
2023-02-01  4:34 ` [PATCH v2 1/5] powerpc: kcsan: Add exclusions from instrumentation Rohan McLure
2023-02-01  4:34 ` [PATCH v2 2/5] powerpc: kcsan: Exclude udelay to prevent recursive instrumentation Rohan McLure
2023-02-01  4:34 ` [PATCH v2 3/5] powerpc: kcsan: Memory barriers semantics Rohan McLure
2023-02-01  4:34 ` [PATCH v2 4/5] powerpc: kcsan: Prevent recursive instrumentation with IRQ save/restores Rohan McLure
2023-02-01  4:34 ` [PATCH v2 5/5] powerpc: kcsan: Add KCSAN Support Rohan McLure
2023-02-04 12:10   ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).