Skip to content

Commit 1f0a674

Browse files
npalixmichal42
authored andcommitted
Coccinelle: Make 'report' the default mode
It appears that the 'report' mode is the one always provided by the semantic patches included in the kernel. It is thus more natural to select it by default. The 'chain' mode is however kept and the 'patch' mode is still the first tried in that case. Signed-off-by: Nicolas Palix <nicolas.palix@imag.fr> Signed-off-by: Michal Marek <mmarek@suse.cz>
1 parent f722406 commit 1f0a674

1 file changed

Lines changed: 11 additions & 3 deletions

File tree

‎scripts/coccicheck‎

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,19 @@ fi
4444

4545
if [ "$MODE" = "" ] ; then
4646
if [ "$ONLINE" = "0" ] ; then
47-
echo 'You have not explicitly specified the mode to use. Using default "chain" mode.'
48-
echo 'All available modes will be tried (in that order): patch, report, context, org'
47+
echo 'You have not explicitly specified the mode to use. Using default "report" mode.'
48+
echo 'Available modes are the following: patch, report, context, org'
4949
echo 'You can specify the mode with "make coccicheck MODE=<mode>"'
50+
echo 'Note however that some modes are not implemented by some semantic patches.'
51+
fi
52+
MODE="report"
53+
fi
54+
55+
if [ "$MODE" = "chain" ] ; then
56+
if [ "$ONLINE" = "0" ] ; then
57+
echo 'You have selected the "chain" mode.'
58+
echo 'All available modes will be tried (in that order): patch, report, context, org'
5059
fi
51-
MODE="chain"
5260
elif [ "$MODE" = "report" -o "$MODE" = "org" ] ; then
5361
FLAGS="$FLAGS -no_show_diff"
5462
fi

0 commit comments

Comments
 (0)