Add scripts/coccinelle/err_cast.cocci
authorNicolas Palix <npalix@diku.dk>
Sun, 6 Jun 2010 15:15:06 +0000 (17:15 +0200)
committerMichal Marek <mmarek@suse.cz>
Fri, 11 Jun 2010 22:00:29 +0000 (00:00 +0200)
commitf853f8305bc2ab24a2f5fb24c4635c645cc7f9d1
treedd397d99cbe8974a9a7daac55a294a7b98c28afb
parent09c35396ecadceb13f0b3fb77da200b6da6a0e37
Add scripts/coccinelle/err_cast.cocci

Add a Coccinelle file to use the ERR_CAST function

Before the release 2.6.25, one had to use ERR_PTR(PTR_ERR(...))  to
convert the pointer type of an error. Since then, the function
ERR_CAST has been available for that purpose.

Signed-off-by: Nicolas Palix <npalix@diku.dk>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Michal Marek <mmarek@suse.cz>
scripts/coccinelle/err_cast.cocci [new file with mode: 0644]