linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vaishali Thakkar <vaishali.thakkar@oracle.com>
To: mmarek@suse.com
Cc: julia.lawall@lip6.fr, gilles.muller@lip6.fr,
	nicolas.palix@imag.fr, lars@metafoo.de, cocci@systeme.lip6.fr,
	linux-kernel@vger.kernel.org,
	Vaishali Thakkar <vaishali.thakkar@oracle.com>
Subject: [PATCH v4 3/3] Coccinelle: misc: Add support for devm variant in all modes
Date: Wed, 23 Nov 2016 14:16:42 +0530	[thread overview]
Message-ID: <a93ba910143703b4ffb45359f95699dfc5e57ffe.1479885093.git.vaishali.thakkar@oracle.com> (raw)
In-Reply-To: <cover.1479885093.git.vaishali.thakkar@oracle.com>

Add missing support for the devm_request_threaded_irq in
the rules of context, report and org modes.

Misc:
----
To be consistent with other scripts, change confidence level
of the script to 'Moderate'.

Signed-off-by: Vaishali Thakkar <vaishali.thakkar@oracle.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
---
Changes since v3:
	- No changes in this patch
Changes since v2:
	- Add missing initialization of metavariables
Changes since v1:
	- Split patch in to the patchset
---
 scripts/coccinelle/misc/irqf_oneshot.cocci | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/scripts/coccinelle/misc/irqf_oneshot.cocci b/scripts/coccinelle/misc/irqf_oneshot.cocci
index cec3672..58c2578 100644
--- a/scripts/coccinelle/misc/irqf_oneshot.cocci
+++ b/scripts/coccinelle/misc/irqf_oneshot.cocci
@@ -5,7 +5,7 @@
 /// So pass the IRQF_ONESHOT flag in this case.
 ///
 //
-// Confidence: Good
+// Confidence: Moderate
 // Comments:
 // Options: --no-includes
 
@@ -79,16 +79,25 @@ devm_request_threaded_irq@p(dev, irq, NULL, thread_fn,
 )
 
 @depends on context@
-expression irq;
+expression dev, irq;
 position p != {r1.p,r2.p};
 @@
+(
 *request_threaded_irq@p(irq, NULL, ...)
+|
+*devm_request_threaded_irq@p(dev, irq, NULL, ...)
+)
+
 
 @match depends on report || org@
-expression irq;
+expression dev, irq;
 position p != {r1.p,r2.p};
 @@
+(
 request_threaded_irq@p(irq, NULL, ...)
+|
+devm_request_threaded_irq@p(dev, irq, NULL, ...)
+)
 
 @script:python depends on org@
 p << match.p;
-- 
2.1.4

  parent reply	other threads:[~2016-11-23  9:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-23  8:42 [PATCH v4 0/3] Coccinelle: misc: Improve the script for more accurate results Vaishali Thakkar
2016-11-23  8:46 ` [PATCH v4 1/3] Coccinelle: misc: Improve the matching of rules Vaishali Thakkar
2016-11-23  8:46 ` Vaishali Thakkar [this message]
2016-11-23  8:46 ` [PATCH v4 2/3] Coccinelle: misc: Improve the result given by context mode Vaishali Thakkar
2016-12-11 11:08 ` [PATCH v4 0/3] Coccinelle: misc: Improve the script for more accurate results Michal Marek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a93ba910143703b4ffb45359f95699dfc5e57ffe.1479885093.git.vaishali.thakkar@oracle.com \
    --to=vaishali.thakkar@oracle.com \
    --cc=cocci@systeme.lip6.fr \
    --cc=gilles.muller@lip6.fr \
    --cc=julia.lawall@lip6.fr \
    --cc=lars@metafoo.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mmarek@suse.com \
    --cc=nicolas.palix@imag.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).