diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2010-11-15 01:33:11 -0500 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-11-15 01:33:11 -0500 |
commit | 1bb95834bbcdc969e477a9284cf96c17a4c2616f (patch) | |
tree | 9cf66b22a611bb6bc78778c05dac72263bb45a23 /scripts/checkpatch.pl | |
parent | 85345517fe6d4de27b0d6ca19fef9d28ac947c4a (diff) | |
parent | a41c73e04673b47730df682446f0d52f95e32a5b (diff) |
Merge remote branch 'airlied/drm-fixes' into drm-intel-fixes
Diffstat (limited to 'scripts/checkpatch.pl')
-rwxr-xr-x | scripts/checkpatch.pl | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 90b54d4697fd..e3c7fc0dca38 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl | |||
@@ -2794,12 +2794,8 @@ sub process { | |||
2794 | WARN("__func__ should be used instead of gcc specific __FUNCTION__\n" . $herecurr); | 2794 | WARN("__func__ should be used instead of gcc specific __FUNCTION__\n" . $herecurr); |
2795 | } | 2795 | } |
2796 | 2796 | ||
2797 | # check for semaphores used as mutexes | 2797 | # check for semaphores initialized locked |
2798 | if ($line =~ /^.\s*(DECLARE_MUTEX|init_MUTEX)\s*\(/) { | 2798 | if ($line =~ /^.\s*sema_init.+,\W?0\W?\)/) { |
2799 | WARN("mutexes are preferred for single holder semaphores\n" . $herecurr); | ||
2800 | } | ||
2801 | # check for semaphores used as mutexes | ||
2802 | if ($line =~ /^.\s*init_MUTEX_LOCKED\s*\(/) { | ||
2803 | WARN("consider using a completion\n" . $herecurr); | 2799 | WARN("consider using a completion\n" . $herecurr); |
2804 | 2800 | ||
2805 | } | 2801 | } |