aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-07-10 19:08:06 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-07-10 19:08:06 -0400
commitae9249493049fd41fa52fc0470251ee1efaabe74 (patch)
treecad8b206dda4caec111877a762f8f590702257de
parentb202c0d5205662fd96f7151afa83f891f2f4d542 (diff)
parentec97946ed038f4b3faa587bc76152b198805b0c4 (diff)
Merge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Pull coccinelle updates from Michal Marek: "The misc branch is reserved for Coccinelle this time: - 'report' is the default mode - MAINTAINERS update for Coccinelle - documentation udate - use new option format for spatch(1) - J=<n> variable to mimic make -j for coccicheck - check for missing pci_free_consistent() calls There are some patches for rpm-pkg and deb-pkg waiting for the 3.12-rc1 merge window" * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: Coccinelle: Update information about the minimal version required Coccinelle: Update the options used to the new option scheme scripts: Coccinelle script for pci_free_consistent() Coccinelle: Update the documentation Coccinelle: Update section of MAINTAINERS coccicheck: span checks across CPUs scripts/coccinelle: check for field address argument to kfree Coccinelle: Update the Coccinelle section of MAINTAINERS Coccinelle: Make 'report' the default mode
-rw-r--r--Documentation/coccinelle.txt63
-rw-r--r--MAINTAINERS3
-rwxr-xr-xscripts/coccicheck76
-rw-r--r--scripts/coccinelle/api/alloc/drop_kmalloc_cast.cocci2
-rw-r--r--scripts/coccinelle/api/alloc/kzalloc-simple.cocci2
-rw-r--r--scripts/coccinelle/api/d_find_alias.cocci2
-rw-r--r--scripts/coccinelle/api/devm_request_and_ioremap.cocci2
-rw-r--r--scripts/coccinelle/api/kstrdup.cocci2
-rw-r--r--scripts/coccinelle/api/memdup.cocci2
-rw-r--r--scripts/coccinelle/api/memdup_user.cocci2
-rw-r--r--scripts/coccinelle/api/ptr_ret.cocci2
-rw-r--r--scripts/coccinelle/api/simple_open.cocci2
-rw-r--r--scripts/coccinelle/free/devm_free.cocci2
-rw-r--r--scripts/coccinelle/free/kfree.cocci2
-rw-r--r--scripts/coccinelle/free/kfreeaddr.cocci32
-rw-r--r--scripts/coccinelle/free/pci_free_consistent.cocci52
-rw-r--r--scripts/coccinelle/iterators/fen.cocci2
-rw-r--r--scripts/coccinelle/iterators/itnull.cocci2
-rw-r--r--scripts/coccinelle/iterators/list_entry_update.cocci2
-rw-r--r--scripts/coccinelle/iterators/use_after_iter.cocci2
-rw-r--r--scripts/coccinelle/locks/call_kern.cocci2
-rw-r--r--scripts/coccinelle/locks/double_lock.cocci2
-rw-r--r--scripts/coccinelle/locks/flags.cocci2
-rw-r--r--scripts/coccinelle/locks/mini_lock.cocci2
-rw-r--r--scripts/coccinelle/misc/boolinit.cocci2
-rw-r--r--scripts/coccinelle/misc/cstptr.cocci2
-rw-r--r--scripts/coccinelle/misc/doubleinit.cocci2
-rw-r--r--scripts/coccinelle/misc/ifaddr.cocci2
-rw-r--r--scripts/coccinelle/misc/ifcol.cocci2
-rw-r--r--scripts/coccinelle/misc/noderef.cocci2
-rw-r--r--scripts/coccinelle/misc/orplus.cocci2
-rw-r--r--scripts/coccinelle/misc/warn.cocci2
-rw-r--r--scripts/coccinelle/null/eno.cocci2
-rw-r--r--scripts/coccinelle/null/kmerr.cocci2
-rw-r--r--scripts/coccinelle/tests/doublebitand.cocci2
-rw-r--r--scripts/coccinelle/tests/doubletest.cocci2
-rw-r--r--scripts/coccinelle/tests/odd_ptr_err.cocci2
37 files changed, 215 insertions, 75 deletions
diff --git a/Documentation/coccinelle.txt b/Documentation/coccinelle.txt
index 18de78599dd4..7f773d51fdd9 100644
--- a/Documentation/coccinelle.txt
+++ b/Documentation/coccinelle.txt
@@ -6,15 +6,17 @@ Copyright 2010 Gilles Muller <Gilles.Muller@lip6.fr>
6 Getting Coccinelle 6 Getting Coccinelle
7~~~~~~~~~~~~~~~~~~~~ 7~~~~~~~~~~~~~~~~~~~~
8 8
9The semantic patches included in the kernel use the 'virtual rule' 9The semantic patches included in the kernel use features and options
10feature which was introduced in Coccinelle version 0.1.11. 10which are provided by Coccinelle version 1.0.0-rc11 and above.
11Using earlier versions will fail as the option names used by
12the Coccinelle files and coccicheck have been updated.
11 13
12Coccinelle (>=0.2.0) is available through the package manager 14Coccinelle is available through the package manager
13of many distributions, e.g. : 15of many distributions, e.g. :
14 16
15 - Debian (>=squeeze) 17 - Debian
16 - Fedora (>=13) 18 - Fedora
17 - Ubuntu (>=10.04 Lucid Lynx) 19 - Ubuntu
18 - OpenSUSE 20 - OpenSUSE
19 - Arch Linux 21 - Arch Linux
20 - NetBSD 22 - NetBSD
@@ -36,11 +38,6 @@ as a regular user, and install it with
36 38
37 sudo make install 39 sudo make install
38 40
39The semantic patches in the kernel will work best with Coccinelle version
400.2.4 or later. Using earlier versions may incur some parse errors in the
41semantic patch code, but any results that are obtained should still be
42correct.
43
44 Using Coccinelle on the Linux kernel 41 Using Coccinelle on the Linux kernel
45~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 42~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
46 43
@@ -48,7 +45,7 @@ A Coccinelle-specific target is defined in the top level
48Makefile. This target is named 'coccicheck' and calls the 'coccicheck' 45Makefile. This target is named 'coccicheck' and calls the 'coccicheck'
49front-end in the 'scripts' directory. 46front-end in the 'scripts' directory.
50 47
51Four modes are defined: patch, report, context, and org. The mode to 48Four basic modes are defined: patch, report, context, and org. The mode to
52use is specified by setting the MODE variable with 'MODE=<mode>'. 49use is specified by setting the MODE variable with 'MODE=<mode>'.
53 50
54'patch' proposes a fix, when possible. 51'patch' proposes a fix, when possible.
@@ -62,18 +59,24 @@ diff-like style.Lines of interest are indicated with '-'.
62'org' generates a report in the Org mode format of Emacs. 59'org' generates a report in the Org mode format of Emacs.
63 60
64Note that not all semantic patches implement all modes. For easy use 61Note that not all semantic patches implement all modes. For easy use
65of Coccinelle, the default mode is "chain" which tries the previous 62of Coccinelle, the default mode is "report".
66modes in the order above until one succeeds. 63
64Two other modes provide some common combinations of these modes.
67 65
68To make a report for every semantic patch, run the following command: 66'chain' tries the previous modes in the order above until one succeeds.
69 67
70 make coccicheck MODE=report 68'rep+ctxt' runs successively the report mode and the context mode.
69 It should be used with the C option (described later)
70 which checks the code on a file basis.
71 71
72NB: The 'report' mode is the default one. 72Examples:
73 To make a report for every semantic patch, run the following command:
73 74
74To produce patches, run: 75 make coccicheck MODE=report
75 76
76 make coccicheck MODE=patch 77 To produce patches, run:
78
79 make coccicheck MODE=patch
77 80
78 81
79The coccicheck target applies every semantic patch available in the 82The coccicheck target applies every semantic patch available in the
@@ -91,6 +94,11 @@ To enable verbose messages set the V= variable, for example:
91 94
92 make coccicheck MODE=report V=1 95 make coccicheck MODE=report V=1
93 96
97By default, coccicheck tries to run as parallel as possible. To change
98the parallelism, set the J= variable. For example, to run across 4 CPUs:
99
100 make coccicheck MODE=report J=4
101
94 102
95 Using Coccinelle with a single semantic patch 103 Using Coccinelle with a single semantic patch
96~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 104~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -124,26 +132,33 @@ To check only newly edited code, use the value 2 for the C flag, i.e.
124 132
125 make C=2 CHECK="scripts/coccicheck" 133 make C=2 CHECK="scripts/coccicheck"
126 134
135In these modes, which works on a file basis, there is no information
136about semantic patches displayed, and no commit message proposed.
137
127This runs every semantic patch in scripts/coccinelle by default. The 138This runs every semantic patch in scripts/coccinelle by default. The
128COCCI variable may additionally be used to only apply a single 139COCCI variable may additionally be used to only apply a single
129semantic patch as shown in the previous section. 140semantic patch as shown in the previous section.
130 141
131The "chain" mode is the default. You can select another one with the 142The "report" mode is the default. You can select another one with the
132MODE variable explained above. 143MODE variable explained above.
133 144
134In this mode, there is no information about semantic patches
135displayed, and no commit message proposed.
136
137 Additional flags 145 Additional flags
138~~~~~~~~~~~~~~~~~~ 146~~~~~~~~~~~~~~~~~~
139 147
140Additional flags can be passed to spatch through the SPFLAGS 148Additional flags can be passed to spatch through the SPFLAGS
141variable. 149variable.
142 150
143 make SPFLAGS=--use_glimpse coccicheck 151 make SPFLAGS=--use-glimpse coccicheck
152 make SPFLAGS=--use-idutils coccicheck
144 153
145See spatch --help to learn more about spatch options. 154See spatch --help to learn more about spatch options.
146 155
156Note that the '--use-glimpse' and '--use-idutils' options
157require external tools for indexing the code. None of them is
158thus active by default. However, by indexing the code with
159one of these tools, and according to the cocci file used,
160spatch could proceed the entire code base more quickly.
161
147 Proposing new semantic patches 162 Proposing new semantic patches
148~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 163~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
149 164
diff --git a/MAINTAINERS b/MAINTAINERS
index e51d01836b54..cbd4f66bc677 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2135,9 +2135,12 @@ COCCINELLE/Semantic Patches (SmPL)
2135M: Julia Lawall <Julia.Lawall@lip6.fr> 2135M: Julia Lawall <Julia.Lawall@lip6.fr>
2136M: Gilles Muller <Gilles.Muller@lip6.fr> 2136M: Gilles Muller <Gilles.Muller@lip6.fr>
2137M: Nicolas Palix <nicolas.palix@imag.fr> 2137M: Nicolas Palix <nicolas.palix@imag.fr>
2138M: Michal Marek <mmarek@suse.cz>
2138L: cocci@systeme.lip6.fr (moderated for non-subscribers) 2139L: cocci@systeme.lip6.fr (moderated for non-subscribers)
2140T: git git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild.git misc
2139W: http://coccinelle.lip6.fr/ 2141W: http://coccinelle.lip6.fr/
2140S: Supported 2142S: Supported
2143F: Documentation/coccinelle.txt
2141F: scripts/coccinelle/ 2144F: scripts/coccinelle/
2142F: scripts/coccicheck 2145F: scripts/coccicheck
2143 2146
diff --git a/scripts/coccicheck b/scripts/coccicheck
index 06fcb3333247..bbf901afb606 100755
--- a/scripts/coccicheck
+++ b/scripts/coccicheck
@@ -1,17 +1,31 @@
1#!/bin/bash 1#!/bin/bash
2 2
3#
4# This script requires at least spatch
5# version 1.0.0-rc11.
6#
7
3SPATCH="`which ${SPATCH:=spatch}`" 8SPATCH="`which ${SPATCH:=spatch}`"
4 9
10trap kill_running SIGTERM SIGINT
11declare -a SPATCH_PID
12
5# The verbosity may be set by the environmental parameter V= 13# The verbosity may be set by the environmental parameter V=
6# as for example with 'make V=1 coccicheck' 14# as for example with 'make V=1 coccicheck'
7 15
8if [ -n "$V" -a "$V" != "0" ]; then 16if [ -n "$V" -a "$V" != "0" ]; then
9 VERBOSE=1 17 VERBOSE="$V"
10else 18else
11 VERBOSE=0 19 VERBOSE=0
12fi 20fi
13 21
14FLAGS="$SPFLAGS -very_quiet" 22if [ -z "$J" ]; then
23 NPROC=$(getconf _NPROCESSORS_ONLN)
24else
25 NPROC="$J"
26fi
27
28FLAGS="$SPFLAGS --very-quiet"
15 29
16# spatch only allows include directories with the syntax "-I include" 30# spatch only allows include directories with the syntax "-I include"
17# while gcc also allows "-Iinclude" and "-include include" 31# while gcc also allows "-Iinclude" and "-include include"
@@ -27,14 +41,14 @@ if [ "$C" = "1" -o "$C" = "2" ]; then
27else 41else
28 ONLINE=0 42 ONLINE=0
29 if [ "$KBUILD_EXTMOD" = "" ] ; then 43 if [ "$KBUILD_EXTMOD" = "" ] ; then
30 OPTIONS="-dir $srctree $COCCIINCLUDE" 44 OPTIONS="--dir $srctree $COCCIINCLUDE"
31 else 45 else
32 OPTIONS="-dir $KBUILD_EXTMOD $COCCIINCLUDE" 46 OPTIONS="--dir $KBUILD_EXTMOD $COCCIINCLUDE"
33 fi 47 fi
34fi 48fi
35 49
36if [ "$KBUILD_EXTMOD" != "" ] ; then 50if [ "$KBUILD_EXTMOD" != "" ] ; then
37 OPTIONS="-patch $srctree $OPTIONS" 51 OPTIONS="--patch $srctree $OPTIONS"
38fi 52fi
39 53
40if [ ! -x "$SPATCH" ]; then 54if [ ! -x "$SPATCH" ]; then
@@ -44,13 +58,21 @@ fi
44 58
45if [ "$MODE" = "" ] ; then 59if [ "$MODE" = "" ] ; then
46 if [ "$ONLINE" = "0" ] ; then 60 if [ "$ONLINE" = "0" ] ; then
47 echo 'You have not explicitly specified the mode to use. Using default "chain" mode.' 61 echo 'You have not explicitly specified the mode to use. Using default "report" mode.'
48 echo 'All available modes will be tried (in that order): patch, report, context, org' 62 echo 'Available modes are the following: patch, report, context, org'
49 echo 'You can specify the mode with "make coccicheck MODE=<mode>"' 63 echo 'You can specify the mode with "make coccicheck MODE=<mode>"'
64 echo 'Note however that some modes are not implemented by some semantic patches.'
65 fi
66 MODE="report"
67fi
68
69if [ "$MODE" = "chain" ] ; then
70 if [ "$ONLINE" = "0" ] ; then
71 echo 'You have selected the "chain" mode.'
72 echo 'All available modes will be tried (in that order): patch, report, context, org'
50 fi 73 fi
51 MODE="chain"
52elif [ "$MODE" = "report" -o "$MODE" = "org" ] ; then 74elif [ "$MODE" = "report" -o "$MODE" = "org" ] ; then
53 FLAGS="$FLAGS -no_show_diff" 75 FLAGS="$FLAGS --no-show-diff"
54fi 76fi
55 77
56if [ "$ONLINE" = "0" ] ; then 78if [ "$ONLINE" = "0" ] ; then
@@ -61,19 +83,35 @@ if [ "$ONLINE" = "0" ] ; then
61fi 83fi
62 84
63run_cmd() { 85run_cmd() {
86 local i
64 if [ $VERBOSE -ne 0 ] ; then 87 if [ $VERBOSE -ne 0 ] ; then
65 echo "Running: $@" 88 echo "Running ($NPROC in parallel): $@"
66 fi 89 fi
67 eval $@ 90 for i in $(seq 0 $(( NPROC - 1)) ); do
91 eval "$@ --max $NPROC --index $i &"
92 SPATCH_PID[$i]=$!
93 if [ $VERBOSE -eq 2 ] ; then
94 echo "${SPATCH_PID[$i]} running"
95 fi
96 done
97 wait
68} 98}
69 99
100kill_running() {
101 for i in $(seq $(( NPROC - 1 )) ); do
102 if [ $VERBOSE -eq 2 ] ; then
103 echo "Killing ${SPATCH_PID[$i]}"
104 fi
105 kill ${SPATCH_PID[$i]} 2>/dev/null
106 done
107}
70 108
71coccinelle () { 109coccinelle () {
72 COCCI="$1" 110 COCCI="$1"
73 111
74 OPT=`grep "Option" $COCCI | cut -d':' -f2` 112 OPT=`grep "Option" $COCCI | cut -d':' -f2`
75 113
76# The option '-parse_cocci' can be used to syntactically check the SmPL files. 114# The option '--parse-cocci' can be used to syntactically check the SmPL files.
77# 115#
78# $SPATCH -D $MODE $FLAGS -parse_cocci $COCCI $OPT > /dev/null 116# $SPATCH -D $MODE $FLAGS -parse_cocci $COCCI $OPT > /dev/null
79 117
@@ -114,20 +152,20 @@ coccinelle () {
114 152
115 if [ "$MODE" = "chain" ] ; then 153 if [ "$MODE" = "chain" ] ; then
116 run_cmd $SPATCH -D patch \ 154 run_cmd $SPATCH -D patch \
117 $FLAGS -sp_file $COCCI $OPT $OPTIONS || \ 155 $FLAGS --cocci-file $COCCI $OPT $OPTIONS || \
118 run_cmd $SPATCH -D report \ 156 run_cmd $SPATCH -D report \
119 $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff || \ 157 $FLAGS --cocci-file $COCCI $OPT $OPTIONS --no-show-diff || \
120 run_cmd $SPATCH -D context \ 158 run_cmd $SPATCH -D context \
121 $FLAGS -sp_file $COCCI $OPT $OPTIONS || \ 159 $FLAGS --cocci-file $COCCI $OPT $OPTIONS || \
122 run_cmd $SPATCH -D org \ 160 run_cmd $SPATCH -D org \
123 $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff || exit 1 161 $FLAGS --cocci-file $COCCI $OPT $OPTIONS --no-show-diff || exit 1
124 elif [ "$MODE" = "rep+ctxt" ] ; then 162 elif [ "$MODE" = "rep+ctxt" ] ; then
125 run_cmd $SPATCH -D report \ 163 run_cmd $SPATCH -D report \
126 $FLAGS -sp_file $COCCI $OPT $OPTIONS -no_show_diff && \ 164 $FLAGS --cocci-file $COCCI $OPT $OPTIONS --no-show-diff && \
127 run_cmd $SPATCH -D context \ 165 run_cmd $SPATCH -D context \
128 $FLAGS -sp_file $COCCI $OPT $OPTIONS || exit 1 166 $FLAGS --cocci-file $COCCI $OPT $OPTIONS || exit 1
129 else 167 else
130 run_cmd $SPATCH -D $MODE $FLAGS -sp_file $COCCI $OPT $OPTIONS || exit 1 168 run_cmd $SPATCH -D $MODE $FLAGS --cocci-file $COCCI $OPT $OPTIONS || exit 1
131 fi 169 fi
132 170
133} 171}
diff --git a/scripts/coccinelle/api/alloc/drop_kmalloc_cast.cocci b/scripts/coccinelle/api/alloc/drop_kmalloc_cast.cocci
index 7d4771d449c3..bd5d08b882ee 100644
--- a/scripts/coccinelle/api/alloc/drop_kmalloc_cast.cocci
+++ b/scripts/coccinelle/api/alloc/drop_kmalloc_cast.cocci
@@ -5,7 +5,7 @@
5// Confidence: High 5// Confidence: High
6// Copyright: 2009,2010 Nicolas Palix, DIKU. GPLv2. 6// Copyright: 2009,2010 Nicolas Palix, DIKU. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Options: -no_includes -include_headers 8// Options: --no-includes --include-headers
9// 9//
10// Keywords: kmalloc, kzalloc, kcalloc 10// Keywords: kmalloc, kzalloc, kcalloc
11// Version min: < 2.6.12 kmalloc 11// Version min: < 2.6.12 kmalloc
diff --git a/scripts/coccinelle/api/alloc/kzalloc-simple.cocci b/scripts/coccinelle/api/alloc/kzalloc-simple.cocci
index 046b9b16f8f9..52c55e4fa67d 100644
--- a/scripts/coccinelle/api/alloc/kzalloc-simple.cocci
+++ b/scripts/coccinelle/api/alloc/kzalloc-simple.cocci
@@ -9,7 +9,7 @@
9// Copyright: (C) 2009-2010 Julia Lawall, Nicolas Palix, DIKU. GPLv2. 9// Copyright: (C) 2009-2010 Julia Lawall, Nicolas Palix, DIKU. GPLv2.
10// Copyright: (C) 2009-2010 Gilles Muller, INRIA/LiP6. GPLv2. 10// Copyright: (C) 2009-2010 Gilles Muller, INRIA/LiP6. GPLv2.
11// URL: http://coccinelle.lip6.fr/rules/kzalloc.html 11// URL: http://coccinelle.lip6.fr/rules/kzalloc.html
12// Options: -no_includes -include_headers 12// Options: --no-includes --include-headers
13// 13//
14// Keywords: kmalloc, kzalloc 14// Keywords: kmalloc, kzalloc
15// Version min: < 2.6.12 kmalloc 15// Version min: < 2.6.12 kmalloc
diff --git a/scripts/coccinelle/api/d_find_alias.cocci b/scripts/coccinelle/api/d_find_alias.cocci
index a9694a8d3e5a..9594c9f7eb8d 100644
--- a/scripts/coccinelle/api/d_find_alias.cocci
+++ b/scripts/coccinelle/api/d_find_alias.cocci
@@ -4,7 +4,7 @@
4// 4//
5// Confidence: Moderate 5// Confidence: Moderate
6// URL: http://coccinelle.lip6.fr/ 6// URL: http://coccinelle.lip6.fr/
7// Options: -include_headers 7// Options: --include-headers
8 8
9virtual context 9virtual context
10virtual org 10virtual org
diff --git a/scripts/coccinelle/api/devm_request_and_ioremap.cocci b/scripts/coccinelle/api/devm_request_and_ioremap.cocci
index 46beb81406ab..562ec88b6352 100644
--- a/scripts/coccinelle/api/devm_request_and_ioremap.cocci
+++ b/scripts/coccinelle/api/devm_request_and_ioremap.cocci
@@ -10,7 +10,7 @@
10// Copyright: (C) 2011 Gilles Muller, INRIA/LiP6. GPLv2. 10// Copyright: (C) 2011 Gilles Muller, INRIA/LiP6. GPLv2.
11// URL: http://coccinelle.lip6.fr/ 11// URL: http://coccinelle.lip6.fr/
12// Comments: 12// Comments:
13// Options: -no_includes -include_headers 13// Options: --no-includes --include-headers
14 14
15virtual patch 15virtual patch
16virtual org 16virtual org
diff --git a/scripts/coccinelle/api/kstrdup.cocci b/scripts/coccinelle/api/kstrdup.cocci
index 07a74b2c6196..09cba54ed0cf 100644
--- a/scripts/coccinelle/api/kstrdup.cocci
+++ b/scripts/coccinelle/api/kstrdup.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual patch 11virtual patch
12virtual context 12virtual context
diff --git a/scripts/coccinelle/api/memdup.cocci b/scripts/coccinelle/api/memdup.cocci
index 4dceab6d54de..3d1aa71b7579 100644
--- a/scripts/coccinelle/api/memdup.cocci
+++ b/scripts/coccinelle/api/memdup.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual patch 11virtual patch
12virtual context 12virtual context
diff --git a/scripts/coccinelle/api/memdup_user.cocci b/scripts/coccinelle/api/memdup_user.cocci
index 2b131a8a1306..c606231b0e46 100644
--- a/scripts/coccinelle/api/memdup_user.cocci
+++ b/scripts/coccinelle/api/memdup_user.cocci
@@ -7,7 +7,7 @@
7// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 7// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
8// URL: http://coccinelle.lip6.fr/ 8// URL: http://coccinelle.lip6.fr/
9// Comments: 9// Comments:
10// Options: -no_includes -include_headers 10// Options: --no-includes --include-headers
11 11
12virtual patch 12virtual patch
13virtual context 13virtual context
diff --git a/scripts/coccinelle/api/ptr_ret.cocci b/scripts/coccinelle/api/ptr_ret.cocci
index 15f076fdecbe..2274638d005b 100644
--- a/scripts/coccinelle/api/ptr_ret.cocci
+++ b/scripts/coccinelle/api/ptr_ret.cocci
@@ -5,7 +5,7 @@
5// Copyright: (C) 2012 Julia Lawall, INRIA/LIP6. GPLv2. 5// Copyright: (C) 2012 Julia Lawall, INRIA/LIP6. GPLv2.
6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Options: -no_includes -include_headers 8// Options: --no-includes --include-headers
9// 9//
10// Keywords: ERR_PTR, PTR_ERR, PTR_RET 10// Keywords: ERR_PTR, PTR_ERR, PTR_RET
11// Version min: 2.6.39 11// Version min: 2.6.39
diff --git a/scripts/coccinelle/api/simple_open.cocci b/scripts/coccinelle/api/simple_open.cocci
index 05962f7be155..b67e174f3d95 100644
--- a/scripts/coccinelle/api/simple_open.cocci
+++ b/scripts/coccinelle/api/simple_open.cocci
@@ -4,7 +4,7 @@
4/// 4///
5// Confidence: High 5// Confidence: High
6// Comments: 6// Comments:
7// Options: -no_includes -include_headers 7// Options: --no-includes --include-headers
8 8
9virtual patch 9virtual patch
10virtual report 10virtual report
diff --git a/scripts/coccinelle/free/devm_free.cocci b/scripts/coccinelle/free/devm_free.cocci
index 0a1e36146d76..3d9349012bb3 100644
--- a/scripts/coccinelle/free/devm_free.cocci
+++ b/scripts/coccinelle/free/devm_free.cocci
@@ -18,7 +18,7 @@
18// Copyright: (C) 2011 Gilles Muller, INRIA/LiP6. GPLv2. 18// Copyright: (C) 2011 Gilles Muller, INRIA/LiP6. GPLv2.
19// URL: http://coccinelle.lip6.fr/ 19// URL: http://coccinelle.lip6.fr/
20// Comments: 20// Comments:
21// Options: -no_includes -include_headers 21// Options: --no-includes --include-headers
22 22
23virtual org 23virtual org
24virtual report 24virtual report
diff --git a/scripts/coccinelle/free/kfree.cocci b/scripts/coccinelle/free/kfree.cocci
index d9ae6d89c2f5..577b78056990 100644
--- a/scripts/coccinelle/free/kfree.cocci
+++ b/scripts/coccinelle/free/kfree.cocci
@@ -10,7 +10,7 @@
10// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 10// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
11// URL: http://coccinelle.lip6.fr/ 11// URL: http://coccinelle.lip6.fr/
12// Comments: 12// Comments:
13// Options: -no_includes -include_headers 13// Options: --no-includes --include-headers
14 14
15virtual org 15virtual org
16virtual report 16virtual report
diff --git a/scripts/coccinelle/free/kfreeaddr.cocci b/scripts/coccinelle/free/kfreeaddr.cocci
new file mode 100644
index 000000000000..ce8aacc314cb
--- /dev/null
+++ b/scripts/coccinelle/free/kfreeaddr.cocci
@@ -0,0 +1,32 @@
1/// Free of a structure field
2///
3// Confidence: High
4// Copyright: (C) 2013 Julia Lawall, INRIA/LIP6. GPLv2.
5// URL: http://coccinelle.lip6.fr/
6// Comments:
7// Options: --no-includes --include-headers
8
9virtual org
10virtual report
11virtual context
12
13@r depends on context || report || org @
14expression e;
15identifier f;
16position p;
17@@
18
19* kfree@p(&e->f)
20
21@script:python depends on org@
22p << r.p;
23@@
24
25cocci.print_main("kfree",p)
26
27@script:python depends on report@
28p << r.p;
29@@
30
31msg = "ERROR: kfree of structure field"
32coccilib.report.print_report(p[0],msg)
diff --git a/scripts/coccinelle/free/pci_free_consistent.cocci b/scripts/coccinelle/free/pci_free_consistent.cocci
new file mode 100644
index 000000000000..43600ccb62a8
--- /dev/null
+++ b/scripts/coccinelle/free/pci_free_consistent.cocci
@@ -0,0 +1,52 @@
1/// Find missing pci_free_consistent for every pci_alloc_consistent.
2///
3// Confidence: Moderate
4// Copyright: (C) 2013 Petr Strnad. GPLv2.
5// URL: http://coccinelle.lip6.fr/
6// Keywords: pci_free_consistent, pci_alloc_consistent
7// Options: --no-includes --include-headers
8
9virtual report
10virtual org
11
12@search@
13local idexpression id;
14expression x,y,z,e;
15position p1,p2;
16type T;
17@@
18
19id = pci_alloc_consistent@p1(x,y,&z)
20... when != e = id
21if (id == NULL || ...) { ... return ...; }
22... when != pci_free_consistent(x,y,id,z)
23 when != if (id) { ... pci_free_consistent(x,y,id,z) ... }
24 when != if (y) { ... pci_free_consistent(x,y,id,z) ... }
25 when != e = (T)id
26 when exists
27(
28return 0;
29|
30return 1;
31|
32return id;
33|
34return@p2 ...;
35)
36
37@script:python depends on report@
38p1 << search.p1;
39p2 << search.p2;
40@@
41
42msg = "ERROR: missing pci_free_consistent; pci_alloc_consistent on line %s and return without freeing on line %s" % (p1[0].line,p2[0].line)
43coccilib.report.print_report(p2[0],msg)
44
45@script:python depends on org@
46p1 << search.p1;
47p2 << search.p2;
48@@
49
50msg = "ERROR: missing pci_free_consistent; pci_alloc_consistent on line %s and return without freeing on line %s" % (p1[0].line,p2[0].line)
51cocci.print_main(msg,p1)
52cocci.print_secs("",p2)
diff --git a/scripts/coccinelle/iterators/fen.cocci b/scripts/coccinelle/iterators/fen.cocci
index 0a40af828c43..48c152f224e1 100644
--- a/scripts/coccinelle/iterators/fen.cocci
+++ b/scripts/coccinelle/iterators/fen.cocci
@@ -7,7 +7,7 @@
7// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 7// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
8// URL: http://coccinelle.lip6.fr/ 8// URL: http://coccinelle.lip6.fr/
9// Comments: 9// Comments:
10// Options: -no_includes -include_headers 10// Options: --no-includes --include-headers
11 11
12virtual patch 12virtual patch
13virtual context 13virtual context
diff --git a/scripts/coccinelle/iterators/itnull.cocci b/scripts/coccinelle/iterators/itnull.cocci
index 259899f6838e..f58732b56a40 100644
--- a/scripts/coccinelle/iterators/itnull.cocci
+++ b/scripts/coccinelle/iterators/itnull.cocci
@@ -11,7 +11,7 @@
11// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 11// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
12// URL: http://coccinelle.lip6.fr/ 12// URL: http://coccinelle.lip6.fr/
13// Comments: 13// Comments:
14// Options: -no_includes -include_headers 14// Options: --no-includes --include-headers
15 15
16virtual patch 16virtual patch
17virtual context 17virtual context
diff --git a/scripts/coccinelle/iterators/list_entry_update.cocci b/scripts/coccinelle/iterators/list_entry_update.cocci
index b2967475679b..873f444e7137 100644
--- a/scripts/coccinelle/iterators/list_entry_update.cocci
+++ b/scripts/coccinelle/iterators/list_entry_update.cocci
@@ -9,7 +9,7 @@
9// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 9// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
10// URL: http://coccinelle.lip6.fr/ 10// URL: http://coccinelle.lip6.fr/
11// Comments: 11// Comments:
12// Options: -no_includes -include_headers 12// Options: --no-includes --include-headers
13 13
14virtual context 14virtual context
15virtual org 15virtual org
diff --git a/scripts/coccinelle/iterators/use_after_iter.cocci b/scripts/coccinelle/iterators/use_after_iter.cocci
index 06284c57a951..f085f5968c52 100644
--- a/scripts/coccinelle/iterators/use_after_iter.cocci
+++ b/scripts/coccinelle/iterators/use_after_iter.cocci
@@ -11,7 +11,7 @@
11// Copyright: (C) 2012 Gilles Muller, INRIA/LIP6. GPLv2. 11// Copyright: (C) 2012 Gilles Muller, INRIA/LIP6. GPLv2.
12// URL: http://coccinelle.lip6.fr/ 12// URL: http://coccinelle.lip6.fr/
13// Comments: 13// Comments:
14// Options: -no_includes -include_headers 14// Options: --no-includes --include-headers
15 15
16virtual context 16virtual context
17virtual org 17virtual org
diff --git a/scripts/coccinelle/locks/call_kern.cocci b/scripts/coccinelle/locks/call_kern.cocci
index 8f10b49603c3..669b24436248 100644
--- a/scripts/coccinelle/locks/call_kern.cocci
+++ b/scripts/coccinelle/locks/call_kern.cocci
@@ -9,7 +9,7 @@
9// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 9// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
10// URL: http://coccinelle.lip6.fr/ 10// URL: http://coccinelle.lip6.fr/
11// Comments: 11// Comments:
12// Options: -no_includes -include_headers 12// Options: --no-includes --include-headers
13 13
14virtual patch 14virtual patch
15virtual context 15virtual context
diff --git a/scripts/coccinelle/locks/double_lock.cocci b/scripts/coccinelle/locks/double_lock.cocci
index 63b24e682fad..002752f97dca 100644
--- a/scripts/coccinelle/locks/double_lock.cocci
+++ b/scripts/coccinelle/locks/double_lock.cocci
@@ -8,7 +8,7 @@
8// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 8// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
9// URL: http://coccinelle.lip6.fr/ 9// URL: http://coccinelle.lip6.fr/
10// Comments: 10// Comments:
11// Options: -no_includes -include_headers 11// Options: --no-includes --include-headers
12 12
13virtual org 13virtual org
14virtual report 14virtual report
diff --git a/scripts/coccinelle/locks/flags.cocci b/scripts/coccinelle/locks/flags.cocci
index 1c4ffe6fd846..debd70e46267 100644
--- a/scripts/coccinelle/locks/flags.cocci
+++ b/scripts/coccinelle/locks/flags.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual context 11virtual context
12virtual org 12virtual org
diff --git a/scripts/coccinelle/locks/mini_lock.cocci b/scripts/coccinelle/locks/mini_lock.cocci
index 3267d7410bd5..47f649b0ea87 100644
--- a/scripts/coccinelle/locks/mini_lock.cocci
+++ b/scripts/coccinelle/locks/mini_lock.cocci
@@ -11,7 +11,7 @@
11// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 11// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
12// URL: http://coccinelle.lip6.fr/ 12// URL: http://coccinelle.lip6.fr/
13// Comments: 13// Comments:
14// Options: -no_includes -include_headers 14// Options: --no-includes --include-headers
15 15
16virtual context 16virtual context
17virtual org 17virtual org
diff --git a/scripts/coccinelle/misc/boolinit.cocci b/scripts/coccinelle/misc/boolinit.cocci
index 97ce41ce8135..b9abed49cd95 100644
--- a/scripts/coccinelle/misc/boolinit.cocci
+++ b/scripts/coccinelle/misc/boolinit.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2012 Julia Lawall, INRIA/LIP6. GPLv2. 6// Copyright: (C) 2012 Julia Lawall, INRIA/LIP6. GPLv2.
7// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 7// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
8// URL: http://coccinelle.lip6.fr/ 8// URL: http://coccinelle.lip6.fr/
9// Options: -include_headers 9// Options: --include-headers
10 10
11virtual patch 11virtual patch
12virtual context 12virtual context
diff --git a/scripts/coccinelle/misc/cstptr.cocci b/scripts/coccinelle/misc/cstptr.cocci
index d42564484528..f0368b3d4563 100644
--- a/scripts/coccinelle/misc/cstptr.cocci
+++ b/scripts/coccinelle/misc/cstptr.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual org 11virtual org
12virtual report 12virtual report
diff --git a/scripts/coccinelle/misc/doubleinit.cocci b/scripts/coccinelle/misc/doubleinit.cocci
index cf74a00cf597..c0c3371d25e0 100644
--- a/scripts/coccinelle/misc/doubleinit.cocci
+++ b/scripts/coccinelle/misc/doubleinit.cocci
@@ -8,7 +8,7 @@
8// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 8// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
9// URL: http://coccinelle.lip6.fr/ 9// URL: http://coccinelle.lip6.fr/
10// Comments: requires at least Coccinelle 0.2.4, lex or parse error otherwise 10// Comments: requires at least Coccinelle 0.2.4, lex or parse error otherwise
11// Options: -no_includes -include_headers 11// Options: --no-includes --include-headers
12 12
13virtual org 13virtual org
14virtual report 14virtual report
diff --git a/scripts/coccinelle/misc/ifaddr.cocci b/scripts/coccinelle/misc/ifaddr.cocci
index 3e4089a77000..8aebd1875e75 100644
--- a/scripts/coccinelle/misc/ifaddr.cocci
+++ b/scripts/coccinelle/misc/ifaddr.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual org 11virtual org
12virtual report 12virtual report
diff --git a/scripts/coccinelle/misc/ifcol.cocci b/scripts/coccinelle/misc/ifcol.cocci
index b7ed91dbeb95..d0d00ef1f12a 100644
--- a/scripts/coccinelle/misc/ifcol.cocci
+++ b/scripts/coccinelle/misc/ifcol.cocci
@@ -13,7 +13,7 @@
13// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 13// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
14// URL: http://coccinelle.lip6.fr/ 14// URL: http://coccinelle.lip6.fr/
15// Comments: 15// Comments:
16// Options: -no_includes -include_headers 16// Options: --no-includes --include-headers
17 17
18virtual org 18virtual org
19virtual report 19virtual report
diff --git a/scripts/coccinelle/misc/noderef.cocci b/scripts/coccinelle/misc/noderef.cocci
index c1707214e602..80a831c91161 100644
--- a/scripts/coccinelle/misc/noderef.cocci
+++ b/scripts/coccinelle/misc/noderef.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual org 11virtual org
12virtual report 12virtual report
diff --git a/scripts/coccinelle/misc/orplus.cocci b/scripts/coccinelle/misc/orplus.cocci
index 4a28cef1484e..81fabf379390 100644
--- a/scripts/coccinelle/misc/orplus.cocci
+++ b/scripts/coccinelle/misc/orplus.cocci
@@ -7,7 +7,7 @@
7// Copyright: (C) 2013 Gilles Muller, INRIA/LIP6. GPLv2. 7// Copyright: (C) 2013 Gilles Muller, INRIA/LIP6. GPLv2.
8// URL: http://coccinelle.lip6.fr/ 8// URL: http://coccinelle.lip6.fr/
9// Comments: 9// Comments:
10// Options: -no_includes -include_headers 10// Options: --no-includes --include-headers
11 11
12virtual org 12virtual org
13virtual report 13virtual report
diff --git a/scripts/coccinelle/misc/warn.cocci b/scripts/coccinelle/misc/warn.cocci
index fda8c3558e4f..d2e5b6cedb84 100644
--- a/scripts/coccinelle/misc/warn.cocci
+++ b/scripts/coccinelle/misc/warn.cocci
@@ -5,7 +5,7 @@
5// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2. 5// Copyright: (C) 2012 Gilles Muller, INRIA/LiP6. GPLv2.
6// URL: http://coccinelle.lip6.fr/ 6// URL: http://coccinelle.lip6.fr/
7// Comments: 7// Comments:
8// Options: -no_includes -include_headers 8// Options: --no-includes --include-headers
9 9
10virtual patch 10virtual patch
11virtual context 11virtual context
diff --git a/scripts/coccinelle/null/eno.cocci b/scripts/coccinelle/null/eno.cocci
index ed961a1f7d11..9bd29aa83399 100644
--- a/scripts/coccinelle/null/eno.cocci
+++ b/scripts/coccinelle/null/eno.cocci
@@ -6,7 +6,7 @@
6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2. 6// Copyright: (C) 2010-2012 Gilles Muller, INRIA/LiP6. GPLv2.
7// URL: http://coccinelle.lip6.fr/ 7// URL: http://coccinelle.lip6.fr/
8// Comments: 8// Comments:
9// Options: -no_includes -include_headers 9// Options: --no-includes --include-headers
10 10
11virtual patch 11virtual patch
12virtual context 12virtual context
diff --git a/scripts/coccinelle/null/kmerr.cocci b/scripts/coccinelle/null/kmerr.cocci
index 949bf656c64c..5354a7903ccb 100644
--- a/scripts/coccinelle/null/kmerr.cocci
+++ b/scripts/coccinelle/null/kmerr.cocci
@@ -10,7 +10,7 @@
10// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 10// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
11// URL: http://coccinelle.lip6.fr/ 11// URL: http://coccinelle.lip6.fr/
12// Comments: 12// Comments:
13// Options: -no_includes -include_headers 13// Options: --no-includes --include-headers
14 14
15virtual context 15virtual context
16virtual org 16virtual org
diff --git a/scripts/coccinelle/tests/doublebitand.cocci b/scripts/coccinelle/tests/doublebitand.cocci
index 9ba73d05a77e..72f1572aaec3 100644
--- a/scripts/coccinelle/tests/doublebitand.cocci
+++ b/scripts/coccinelle/tests/doublebitand.cocci
@@ -10,7 +10,7 @@
10// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 10// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
11// URL: http://coccinelle.lip6.fr/ 11// URL: http://coccinelle.lip6.fr/
12// Comments: 12// Comments:
13// Options: -no_includes -include_headers 13// Options: --no-includes --include-headers
14 14
15virtual context 15virtual context
16virtual org 16virtual org
diff --git a/scripts/coccinelle/tests/doubletest.cocci b/scripts/coccinelle/tests/doubletest.cocci
index 13a2c0e8a4bf..78d74c22ca12 100644
--- a/scripts/coccinelle/tests/doubletest.cocci
+++ b/scripts/coccinelle/tests/doubletest.cocci
@@ -8,7 +8,7 @@
8// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2. 8// Copyright: (C) 2010 Gilles Muller, INRIA/LiP6. GPLv2.
9// URL: http://coccinelle.lip6.fr/ 9// URL: http://coccinelle.lip6.fr/
10// Comments: 10// Comments:
11// Options: -no_includes -include_headers 11// Options: --no-includes --include-headers
12 12
13virtual context 13virtual context
14virtual org 14virtual org
diff --git a/scripts/coccinelle/tests/odd_ptr_err.cocci b/scripts/coccinelle/tests/odd_ptr_err.cocci
index e8dd8a6b28a2..cfe0a35cf2dd 100644
--- a/scripts/coccinelle/tests/odd_ptr_err.cocci
+++ b/scripts/coccinelle/tests/odd_ptr_err.cocci
@@ -7,7 +7,7 @@
7// Copyright: (C) 2012 Gilles Muller, INRIA. GPLv2. 7// Copyright: (C) 2012 Gilles Muller, INRIA. GPLv2.
8// URL: http://coccinelle.lip6.fr/ 8// URL: http://coccinelle.lip6.fr/
9// Comments: 9// Comments:
10// Options: -no_includes -include_headers 10// Options: --no-includes --include-headers
11 11
12virtual patch 12virtual patch
13virtual context 13virtual context