From 064d14339537dec6dc5d5cc12233621ebb2d2431 Mon Sep 17 00:00:00 2001 From: Joe Perches Date: Mon, 17 Dec 2012 16:02:00 -0800 Subject: [PATCH] --- yaml --- r: 346421 b: refs/heads/master c: 88982fea52d0115d44b77619afef576f24cdb844 h: refs/heads/master i: 346419: d41389ae068919196f39cfd81e288bed498d1a3a v: v3 --- [refs] | 2 +- trunk/scripts/checkpatch.pl | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index ea5c7493ede0..33cf21540a5b 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 0979ae66464bd9793c6701861bccb21f9f118a52 +refs/heads/master: 88982fea52d0115d44b77619afef576f24cdb844 diff --git a/trunk/scripts/checkpatch.pl b/trunk/scripts/checkpatch.pl index e0a674f471ee..f27b0b53e3ea 100755 --- a/trunk/scripts/checkpatch.pl +++ b/trunk/scripts/checkpatch.pl @@ -3336,6 +3336,12 @@ sub process { "Avoid line continuations in quoted strings\n" . $herecurr); } +# check for struct spinlock declarations + if ($line =~ /^.\s*\bstruct\s+spinlock\s+\w+\s*;/) { + WARN("USE_SPINLOCK_T", + "struct spinlock should be spinlock_t\n" . $herecurr); + } + # Check for misused memsets if ($^V && $^V ge 5.10.0 && defined $stat &&