aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/scripts/checkpatch.pl
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2020-06-11 20:02:46 +0200
committerThomas Gleixner <tglx@linutronix.de>2020-06-11 20:02:46 +0200
commit37d1a04b13a6d2fec91a6813fc034947a27db034 (patch)
treec6a8d7d0df96a6eb1ddb53a12885761cb72e0e92 /scripts/checkpatch.pl
parentlocking/atomics: Flip fallbacks and instrumentation (diff)
parentMerge branch 'kcsan-for-tip' of git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu into locking/kcsan (diff)
downloadwireguard-linux-37d1a04b13a6d2fec91a6813fc034947a27db034.tar.xz
wireguard-linux-37d1a04b13a6d2fec91a6813fc034947a27db034.zip
Rebase locking/kcsan to locking/urgent
Merge the state of the locking kcsan branch before the read/write_once() and the atomics modifications got merged. Squash the fallout of the rebase on top of the read/write once and atomic fallback work into the merge. The history of the original branch is preserved in tag locking-kcsan-2020-06-02. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'scripts/checkpatch.pl')
-rwxr-xr-xscripts/checkpatch.pl8
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 197436b20288..cfb5d42c54de 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -5945,6 +5945,14 @@ sub process {
}
}
+# check for data_race without a comment.
+ if ($line =~ /\bdata_race\s*\(/) {
+ if (!ctx_has_comment($first_line, $linenr)) {
+ WARN("DATA_RACE",
+ "data_race without comment\n" . $herecurr);
+ }
+ }
+
# check for smp_read_barrier_depends and read_barrier_depends
if (!$file && $line =~ /\b(smp_|)read_barrier_depends\s*\(/) {
WARN("READ_BARRIER_DEPENDS",