summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorNicolas Palix <nicolas.palix@imag.fr>2012-09-21 00:30:46 +0400
committerMichal Marek <mmarek@suse.cz>2012-10-11 17:11:12 +0400
commitc05cd6ddb6fce23123c62db36a4ce09da4f29dc1 (patch)
tree4a71b3ed422fe4d8d2a22dea3df53051cfc0a7fe /scripts
parente8fa600e066f137ef5810a2a5021530d68f34ac9 (diff)
downloadlinux-c05cd6ddb6fce23123c62db36a4ce09da4f29dc1.tar.xz
coccicheck: Add the rep+ctxt mode
This adds a 'rep+ctxt' mode which prints the warning message followed by the context. Signed-off-by: Nicolas Palix <nicolas.palix@imag.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/coccicheck3
1 files changed, 3 insertions, 0 deletions
diff --git a/scripts/coccicheck b/scripts/coccicheck
index 823e972149e5..1a49d1c7ecfe 100755
--- a/scripts/coccicheck
+++ b/scripts/coccicheck
@@ -95,6 +95,9 @@ coccinelle () {
$SPATCH -D report $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff || \
$SPATCH -D context $FLAGS -sp_file $COCCI $OPT $OPTIONS || \
$SPATCH -D org $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff || exit 1
+ elif [ "$MODE" = "rep+ctxt" ] ; then
+ $SPATCH -D report $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff && \
+ $SPATCH -D context $FLAGS -sp_file $COCCI $OPT $OPTIONS || exit 1
else
$SPATCH -D $MODE $FLAGS -sp_file $COCCI $OPT $OPTIONS || exit 1
fi