From: SF Markus Elfring <elfring@users.sourceforge.net>
To: cocci@systeme.lip6.fr,
Masahiro Yamada <yamada.masahiro@socionext.com>,
Himanshu Jha <himanshujha199640@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
kernel-janitors@vger.kernel.org,
Gilles Muller <Gilles.Muller@lip6.fr>,
"Luis R. Rodriguez" <mcgrof@kernel.org>,
Michal Marek <michal.lkml@markovi.net>,
Nicolas Palix <nicolas.palix@imag.fr>
Subject: Re: [v2] Coccinelle: zalloc-simple: Delete function “kmem_cache_alloc” from SmPL rules
Date: Wed, 31 Jan 2018 18:28:13 +0100 [thread overview]
Message-ID: <243e83a2-ae0c-2dd2-7f8f-83ac0978cc0e@users.sourceforge.net> (raw)
In-Reply-To: <CAK7LNAR27r4j4c1FCh_ObpMpBKXgSP6Vq3P=reA-JKoTji6Q1A@mail.gmail.com>
> I removed the blank line at EOF,
> then applied to linux-kbuild/misc.
I have taken another look at this script for the semantic patch language.
I imagined that I could refactor the shown SmPL disjunctions a bit.
But I noticed then that these SmPL rules contain a development mistake.
The deletion for a call of the function “memset” depends on the specification
that a size determination is passed by the expression “E1”.
The function “kmem_cache_alloc” was specified despite of the technical detail
that this function does not get a parameter passed which would correspond
to such a size information.
https://elixir.free-electrons.com/linux/v4.15/source/tools/testing/radix-tree/linux/slab.h#L14
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/tree/tools/testing/radix-tree/linux/slab.h?id=537659c08a7da298aa748854f65f2aa1f31b1378#n14
Thus I suggest to remove it from the first two SmPL rules and omit the rule “r4”.
Will the rule set be more consistent then?
Regards,
Markus
next prev parent reply other threads:[~2018-01-31 17:28 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-26 21:40 [PATCH v2] Coccinelle: kzalloc-simple: Add all zero allocating functions Himanshu Jha
2017-12-26 21:52 ` Julia Lawall
2017-12-29 17:22 ` Masahiro Yamada
2017-12-29 17:49 ` Julia Lawall
2018-01-02 14:25 ` Rename the SmPL script “kzalloc-….cocci”? SF Markus Elfring
2018-01-02 14:28 ` Julia Lawall
2018-01-02 14:38 ` SF Markus Elfring
2018-01-02 14:43 ` Julia Lawall
2018-01-02 15:00 ` SF Markus Elfring
2018-01-08 9:55 ` SF Markus Elfring
2018-01-03 11:55 ` [PATCH] Coccinelle: Rename the script for a transformation of memory allocations SF Markus Elfring
2018-01-03 12:02 ` Julia Lawall
2018-01-03 12:13 ` SF Markus Elfring
2018-01-03 12:17 ` Julia Lawall
2018-01-03 12:31 ` SF Markus Elfring
2018-01-03 12:40 ` Julia Lawall
2018-01-03 12:45 ` SF Markus Elfring
2018-01-04 8:36 ` SF Markus Elfring
2018-01-04 8:54 ` Julia Lawall
2018-01-04 9:43 ` SF Markus Elfring
2018-01-17 16:47 ` [v2] Coccinelle: zalloc-simple: Safer transformations with SmPL SF Markus Elfring
2018-01-19 16:14 ` Coccinelle: zalloc-simple: Checking consequences from the usage of at signs in Python strings SF Markus Elfring
2018-01-19 16:18 ` Julia Lawall
2018-01-19 16:43 ` SF Markus Elfring
2018-01-24 8:41 ` SF Markus Elfring
2018-01-31 17:28 ` SF Markus Elfring [this message]
2018-01-31 17:38 ` [v2] Coccinelle: zalloc-simple: Delete function “kmem_cache_alloc” from SmPL rules Julia Lawall
2018-01-31 17:53 ` SF Markus Elfring
2018-02-01 9:35 ` [PATCH] Coccinelle: zalloc-simple: Delete function "kmem_cache_alloc" " SF Markus Elfring
2018-02-01 9:40 ` Julia Lawall
2018-02-01 10:17 ` SF Markus Elfring
2018-02-01 10:27 ` Julia Lawall
2018-02-01 11:00 ` SF Markus Elfring
2018-02-03 7:22 ` Coccinelle: zalloc-simple: Checking consistency for " SF Markus Elfring
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=243e83a2-ae0c-2dd2-7f8f-83ac0978cc0e@users.sourceforge.net \
--to=elfring@users.sourceforge.net \
--cc=Gilles.Muller@lip6.fr \
--cc=cocci@systeme.lip6.fr \
--cc=himanshujha199640@gmail.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mcgrof@kernel.org \
--cc=michal.lkml@markovi.net \
--cc=nicolas.palix@imag.fr \
--cc=yamada.masahiro@socionext.com \
/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