> @@
> type M;
This?
struct monitor* m;
> @@
> - m->virtual.width;
> + get_monitor_width();
signature.asc
Description: PGP signature
___
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci
On Fri, Feb 14, 2020 at 01:23:16PM +0100, Markus Elfring wrote:
> > I cloned coccinelle's GIT repository, I suggested a patch,
> > and the patch has been accepted.
>
> Will the chances increase for further contributions?
Why do you want to know?
signature.asc
Description: PGP signature
> these drivers pop up, I think we can have another function like
> platform_get_irq_probe() or platform_get_irq_nowarn() that doesn't print
> an error message. Then we can convert the drivers that are poking around
> for interrupts to use this new function instead. It isn't the same as a
>
Hi Stephen,
> There were some comments about adding an 'optional' platform_get_irq()
> API in v4. This series doesn't include that, but I can add such an API
> if it's required. I started to look into how it might work and got hung
> up on what an optional IRQ means. I suppose it means that in DT
Hi,
On Sat, Feb 16, 2019 at 09:57:54AM +0100, Markus Elfring wrote:
> > We don't need perfection.
>
> I guess that you noticed in the meantime that I dare to propose
> more software development efforts in such a direction.
Yes, this is noticable. It is your choice, however, other people may
Julia,
> > received the Eurosys "Test of Time" award. Many thanks to everyone on
> > this list who has helped to make this possible.
Congratulations from me, too! Very well deserved!
> Warming people up, ready for the major award for Coccinelle
What would that be?
Best wishes,
> I am working on a more general solution, extending to other functions.
Sounds good, thanks!
signature.asc
Description: PGP signature
___
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci
On Thu, Jun 30, 2016 at 12:03:47AM +0530, Amitoj Kaur Chawla wrote:
> This script detects cases which have incorrect error handling for
> devm_ioremap_resource function, employing a NULL test instead of an
> IS_ERR() test.
>
> Signed-off-by: Amitoj Kaur Chawla
Why don't we
> Is there another scripts/coccinelle/ file I can use to test against to demo
> against glimpse/idutils/gitgrep best?
I'd think this one may be a candidate:
scripts/coccinelle/misc/irqf_oneshot.cocci
Not too many, but quite some matches over the tree.
signature.asc
Description: PGP
> works pretty well, and there are quite a lot of files (7514) that contain
> kfree.
Ah, kfree. That explains, I missed that info.
signature.asc
Description: PGP signature
___
Cocci mailing list
Cocci@systeme.lip6.fr
> It's not as efficient as glimpse because the query language is simpler.
Interesting, what is missing compared to glimpse?
> So more filtering has to be done at the ocaml level. But it's probably
> fine in most cases.
For me, it has two advantages over glimpse:
a) it is in the debian
> real16m11.692s
> user127m50.388s
> sys 0m2.168s
That's better but not a magnitude, I wonder.
signature.asc
Description: PGP signature
___
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci
> AFAICT coccinelle does not have integration support for id-utils though.
I used it just today ;) -- "--use-idutils ./ID"
ID was generated with simple 'mkid -s'.
signature.asc
Description: PGP signature
___
Cocci mailing list
Cocci@systeme.lip6.fr
> > Well, slightly better.
>
> No, it should be much better. You would have to look at the standard
I use id-utils regularly and it is indeed at least a magnitude better.
The indexing often pays off already with the first coccinelle run for
me. Highly recommended.
signature.asc
Description:
.com>
> Signed-off-by: Vaishali Thakkar <vaishali.thak...@oracle.com>
Tested-by: Wolfram Sang <w...@the-dreams.de>
Can we have this in 4.6 as a bugfix? The script is totally broken this
way.
signature.asc
Description: PGP signature
___
C
On Sat, Mar 19, 2016 at 06:43:08PM +0100, Julia Lawall wrote:
> On Sat, 19 Mar 2016, Wolfram Sang wrote:
>
> > The header mentions this check depends on personal taste. I agree.
> > Running coccicheck on patches before I apply them, this SmPL produced
> > enough false p
> The isomorphism that allows ignoring a cast only works when the type
> metavariable is used only once. You uare using it twice. The fact that
> you wanted to add it indicates that you really want it to be there.
Aha, I understand. Thank you for the explanation!
> I think that everything
Hi,
using Coccinelle v1.04 from Debian:
$ spatch -version
spatch version 1.0.4 with Python support and with PCRE support
The following semantic patch produces a match with current linux-next:
@@
expression table, dev;
type T;
@@
- (T)of_match_device(table, dev)->data
+
On Sun, Apr 19, 2015 at 05:37:21PM +0200, Julia Lawall wrote:
Coccinelle version 1.0.0 is released.
Congratulations, Julia! And thank you *very much* for all your hard
work!
All the best,
Wolfram
signature.asc
Description: Digital signature
___
On Sun, Dec 21, 2014 at 11:39:14AM +0100, Julia Lawall wrote:
On Sun, 21 Dec 2014, Wolfram Sang wrote:
does not result in anything although three drivers should match IMO with
the same pattern as the pmu driver above. Both use
platform_driver_register() and both have the .owner
On Fri, Nov 07, 2014 at 06:51:05PM +0100, Wolfram Sang wrote:
On Tue, Oct 28, 2014 at 03:18:24PM -0200, Mauro Carvalho Chehab wrote:
The comma after --no-includes makes coccinelle to not run the script:
/usr/bin/spatch -D report --very-quiet --no-show-diff --cocci-file
./scripts
...
At least with Fedora 20 coccinelle package:
coccinelle-1.0.0-0.rc20.1.fc21.x86_64
Signed-off-by: Mauro Carvalho Chehab mche...@osg.samsung.com
Yay, with this my patch handling scripts finally work again as they used
to! Please let it go into 3.18.
Tested-by: Wolfram Sang w
On Sat, Oct 18, 2014 at 08:02:00AM +0200, Julia Lawall wrote:
@fix1_context depends on match1 !patch (context || org || report)@
identifier match1.__driver;
position j0;
@@
* static struct platform_driver __driver@j0 = {
.driver = {
.owner =
= {
.driver = {
- .owner = THIS_MODULE,
}
};
// Generated config
description = Remove .owner field if calls are used which set it automatically
confidence = Moderate
authors = Wolfram Sang. GPL v2.
fix2 =
org:No need to set .owner here
So, what is your opinion on the original cleanup series removing
unnecessary '.owner = THIS_MODULE' lines in drivers? Helpful? Noise?
Helpful, please do it. I can take it all through my driver-core tree if
you want, that might make things easier for others.
Thanks, that might make sense
You got me wondering, though, that it could not be correct to call
platform_driver_register() from the platform core instead of module
init. I will check tomorrow. Still, this would be a bug independent of
my series. Although I'd need to respin it if platform_driver_probe()
needed a
on linux-next
of yesterday):
git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux.git
drop_platform_driver_owner
This still results in 300 patches as this shortened pull request shows:
===
Wolfram Sang (299):
ARM: common: drop owner assignment from platform_drivers
ARM: mach-davinci
The semantic patch looks fine.
Wow, nothing to improve on the semantic patch? Now I am proud :) Thanks
Julia for your support, as always!
If you think that it would be useful to have this in the Linux kernel, so
people don't add the owner initializer back in the future, you can try
Hi Arnd,
thanks for taking a look!
On Fri, Oct 10, 2014 at 10:30:08AM +0200, Arnd Bergmann wrote:
On Friday 10 October 2014 09:24:39 Wolfram Sang wrote:
people found out that for platform_driver, we don't need to set the
.owner field because this is done by the platform driver core. So far
On Fri, Oct 10, 2014 at 09:36:27AM +0100, Russell King - ARM Linux wrote:
On Fri, Oct 10, 2014 at 09:24:39AM +0200, Wolfram Sang wrote:
people found out that for platform_driver, we don't need to set the
.owner field because this is done by the platform driver core. So far,
so good. However
I have searched a bit in a few archives.
Really? This is what my search found in approx. 3 seconds (assuming
SUSE):
http://rpm.pbone.net/index.php3/stat/3/srodzaj/1/search/tex%28ptmr8t.tfm%29
signature.asc
Description: Digital signature
___
Cocci
The tool RPM PBone Search was not on my radar screen for a while.
It was the first hit for me when it googled suse and the font name :)
Anyway, glad it works now...
signature.asc
Description: Digital signature
___
Cocci mailing list
On Sun, Apr 27, 2014 at 02:29:46AM +0200, Javier Martinez Canillas wrote:
Using the BIT() macro instead of manually shifting bits
makes the code less error prone and also more readable.
Does it? It is a taste thing, yet I don't think it makes the code that
much more readable that it is worth
Hi,
using the latest Debian package from testing (rc18) and the following
spatch on the Linux Kernel:
@@
expression e;
@@
- INIT_COMPLETION(e);
+ reinit_completion(e);
Running with:
spatch --sp-file /tmp/reinit_completion.cocci --use-idutils --include-headers ./
I get:
On Thu, Aug 15, 2013 at 12:30:25PM +0200, Wolfram Sang wrote:
Use of this function is discouraged in favour of
devm_ioremap_resource(). Don't advertise it.
Signed-off-by: Wolfram Sang w...@the-dreams.de
Ping.
signature.asc
Description: Digital signature
Hi,
I'd basically need something like:
if (... when != var)
to match. I couldn't find a way to express it. This is needed since
there are constructs like:
if (var = something())
which I don't want to match since they assign var a value which is fine
in my case.
Thanks,
I'd basically need something like:
if (... when != var)
This is not really clear enough for me to understand what you do want to
do. I imagine that you want something like
(
if (pattern_you_like) S1 else S2
|
* if (pattern_you_dont_like)
S1 else S2
)
Ah, so I was on a
Hi,
This spatch:
@@
int *p;
@@
- int *p;
with this code:
int main()
{
int *a;
return 0;
}
results in:
Fatal error: exception Failure(minus: parse error:
= File test.cocci, line 5, column 7, charpos = 22
around = 'p', whole content = - int *p;
)
using:
Hi,
I wanted to try id-utils in comparison with grep, but I can't find the
script 'idindex-cocci.sh' mentioned in the doc files. Not even in older
releases. Does someone still have it? Is id-utils still supported? And
while I am here, any outcome of the suggestion to use cscope?
Thanks,
Hi,
I wanted to try the --id-utils option to see what the speedup was like.
The docs mention a script called 'idindex-cocci.sh' to generate the
index but I am unable to find it (no luck in older version of
coccinelle, too). Does someone still have it? And in one older mail
thread cscope was
Hi,
using 1.0-rc16 from debian, I use the following semantic patch:
@@
expression r, p, n;
@@
r = platform_get_resource(p, IORESOURCE_MEM, n);
...
(
- if (!r) { ... }
|
- if (unlikely(!r)) { ... }
|
- if (unlikely(r == NULL)) { ... }
)
and running against the
There is already an isomorphism for unlikely. But it is in one direction
only, so 'unlikely(E)' in your cocci script will also match 'E', but 'E'
wont match 'unlikely(E)'.
Okay, but I would then still need 'unlikely(!r)' and 'unlikely(r ==
NULL)' because the !r isomorphisms won't apply. I'd
42 matches
Mail list logo