* [cocci] EXN: Coccinelle_modules.Common.Timeout
@ 2024-01-07 18:35 Jakub Kicinski
2024-01-07 18:52 ` Julia Lawall
2024-01-07 20:15 ` [cocci] EXN: Coccinelle_modules.Common.Timeout Julia Lawall
0 siblings, 2 replies; 5+ messages in thread
From: Jakub Kicinski @ 2024-01-07 18:35 UTC (permalink / raw)
To: Julia Lawall, Nicolas Palix; +Cc: cocci
Hi!
When running coccicheck on net-next I get:
/usr/local/bin/spatch -D report --no-show-diff --very-quiet --cocci-file ./scripts/coccinelle/free/clk_put.cocci --dir . -I ./arch/x86/include -I ./arch/x86/include/generated -I ./include -I ./arch/x86/include/uapi -I ./arch/x86/include/generated/uapi -I ./include/uapi -I ./include/generated/uapi --include ./include/linux/compiler-version.h --include ./include/linux/kconfig.h --jobs 64 --chunksize 1
158 files match
./drivers/bus/ti-sysc.c:2362:2-8: ERROR: missing clk_put; clk_get on line 2354 and execution via conditional on line 2361
./drivers/tty/serial/bcm63xx_uart.c:850:2-8: ERROR: missing clk_put; clk_get on line 845 and execution via conditional on line 849
EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/armada-8k-cpufreq.c
EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/mvebu-cpufreq.c
An error occurred when attempting to transform some files.
coccicheck failed
make[1]: *** [/home/cocci/testing/Makefile:2003: coccicheck] Error 255
make: *** [Makefile:234: __sub-make] Error 2
I couldn't google out any meaningful info about this. Is the timeout
something I can increase locally? Is something wrong?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [cocci] EXN: Coccinelle_modules.Common.Timeout
2024-01-07 18:35 [cocci] EXN: Coccinelle_modules.Common.Timeout Jakub Kicinski
@ 2024-01-07 18:52 ` Julia Lawall
2024-01-08 7:30 ` [cocci] Reconsidering error handling strategy for coccicheck Markus Elfring
2024-01-07 20:15 ` [cocci] EXN: Coccinelle_modules.Common.Timeout Julia Lawall
1 sibling, 1 reply; 5+ messages in thread
From: Julia Lawall @ 2024-01-07 18:52 UTC (permalink / raw)
To: Jakub Kicinski; +Cc: Nicolas Palix, cocci
[-- Attachment #1: Type: text/plain, Size: 2180 bytes --]
On Sun, 7 Jan 2024, Jakub Kicinski wrote:
> Hi!
>
> When running coccicheck on net-next I get:
>
> /usr/local/bin/spatch -D report --no-show-diff --very-quiet --cocci-file ./scripts/coccinelle/free/clk_put.cocci --dir . -I ./arch/x86/include -I ./arch/x86/include/generated -I ./include -I ./arch/x86/include/uapi -I ./arch/x86/include/generated/uapi -I ./include/uapi -I ./include/generated/uapi --include ./include/linux/compiler-version.h --include ./include/linux/kconfig.h --jobs 64 --chunksize 1
> 158 files match
> ./drivers/bus/ti-sysc.c:2362:2-8: ERROR: missing clk_put; clk_get on line 2354 and execution via conditional on line 2361
> ./drivers/tty/serial/bcm63xx_uart.c:850:2-8: ERROR: missing clk_put; clk_get on line 845 and execution via conditional on line 849
> EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/armada-8k-cpufreq.c
> EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/mvebu-cpufreq.c
> An error occurred when attempting to transform some files.
> coccicheck failed
> make[1]: *** [/home/cocci/testing/Makefile:2003: coccicheck] Error 255
> make: *** [Makefile:234: __sub-make] Error 2
>
>
> I couldn't google out any meaningful info about this. Is the timeout
> something I can increase locally? Is something wrong?
The documentation says:
You can use SPFLAGS to add debugging flags, for instance you may want to
add both –profile –show-trying to SPFLAGS when debugging. For instance you
may want to use:
rm -f err.log
export COCCI=scripts/coccinelle/misc/irqf_oneshot.cocci
make coccicheck DEBUG_FILE="err.log" MODE=report SPFLAGS="--profile --show-trying" M=./drivers/mfd/arizona-irq.c
So you could say SPFLAGS="--timeout 200", for example.
But the real problem is that Coccinelle was changed at some point to fail
if anything failed. Whereas in many situations, like here, that is highly
undesirable. The original motivation was to avoid partial
transformations, but I think it is better that users just monitor the
output to see if there is a risk of that. Having the most complete
attempt to perform the transformation is almost always better, because it
can help the user figure out what to improve.
julia
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [cocci] EXN: Coccinelle_modules.Common.Timeout
2024-01-07 18:35 [cocci] EXN: Coccinelle_modules.Common.Timeout Jakub Kicinski
2024-01-07 18:52 ` Julia Lawall
@ 2024-01-07 20:15 ` Julia Lawall
[not found] ` <20240107144227.273e0233@kernel.org>
1 sibling, 1 reply; 5+ messages in thread
From: Julia Lawall @ 2024-01-07 20:15 UTC (permalink / raw)
To: Jakub Kicinski; +Cc: Nicolas Palix, cocci
On Sun, 7 Jan 2024, Jakub Kicinski wrote:
> Hi!
>
> When running coccicheck on net-next I get:
>
> /usr/local/bin/spatch -D report --no-show-diff --very-quiet --cocci-file ./scripts/coccinelle/free/clk_put.cocci --dir . -I ./arch/x86/include -I ./arch/x86/include/generated -I ./include -I ./arch/x86/include/uapi -I ./arch/x86/include/generated/uapi -I ./include/uapi -I ./include/generated/uapi --include ./include/linux/compiler-version.h --include ./include/linux/kconfig.h --jobs 64 --chunksize 1
> 158 files match
> ./drivers/bus/ti-sysc.c:2362:2-8: ERROR: missing clk_put; clk_get on line 2354 and execution via conditional on line 2361
> ./drivers/tty/serial/bcm63xx_uart.c:850:2-8: ERROR: missing clk_put; clk_get on line 845 and execution via conditional on line 849
> EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/armada-8k-cpufreq.c
> EXN: Coccinelle_modules.Common.Timeout in ./drivers/cpufreq/mvebu-cpufreq.c
> An error occurred when attempting to transform some files.
> coccicheck failed
> make[1]: *** [/home/cocci/testing/Makefile:2003: coccicheck] Error 255
> make: *** [Makefile:234: __sub-make] Error 2
>
>
> I couldn't google out any meaningful info about this. Is the timeout
> something I can increase locally? Is something wrong?
Perhaps if you pull from github it will work better now, ie keep going
after the timeouts.
julia
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [cocci] EXN: Coccinelle_modules.Common.Timeout
[not found] ` <20240107144227.273e0233@kernel.org>
@ 2024-01-08 6:37 ` Julia Lawall
0 siblings, 0 replies; 5+ messages in thread
From: Julia Lawall @ 2024-01-08 6:37 UTC (permalink / raw)
To: Jakub Kicinski; +Cc: Nicolas Palix, cocci
On Sun, 7 Jan 2024, Jakub Kicinski wrote:
> On Sun, 7 Jan 2024 21:15:54 +0100 (CET) Julia Lawall wrote:
> > > I couldn't google out any meaningful info about this. Is the timeout
> > > something I can increase locally? Is something wrong?
> >
> > Perhaps if you pull from github it will work better now, ie keep going
> > after the timeouts.
>
> Thank you! I fetched from github, and after an hour it's still making
> progress, previously it error'ed out after 10 minutes or so!
Great.
> Next issue.. :) when I run with --use-patch-diff commit1..commit2
> I get these three lines for every spatch run:
>
> grep: warning: + at start of expression
> grep: warning: + at start of expression
> grep: warning: + at start of expression
OK, will look into it. I think this comes from coccicheck, not from
Coccinelle.
julia
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [cocci] Reconsidering error handling strategy for coccicheck
2024-01-07 18:52 ` Julia Lawall
@ 2024-01-08 7:30 ` Markus Elfring
0 siblings, 0 replies; 5+ messages in thread
From: Markus Elfring @ 2024-01-08 7:30 UTC (permalink / raw)
To: Julia Lawall, Jakub Kicinski, cocci; +Cc: Nicolas Palix
> But the real problem is that Coccinelle was changed at some point to fail
> if anything failed.
See also:
adjust treatment of patching_failed
2022-09-05
https://gitlab.inria.fr/coccinelle/coccinelle/-/commit/5448bb2bd03491ffec356bf7bd6ddcdbf4d36bc9
Regards,
Markus
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-01-08 7:31 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-07 18:35 [cocci] EXN: Coccinelle_modules.Common.Timeout Jakub Kicinski
2024-01-07 18:52 ` Julia Lawall
2024-01-08 7:30 ` [cocci] Reconsidering error handling strategy for coccicheck Markus Elfring
2024-01-07 20:15 ` [cocci] EXN: Coccinelle_modules.Common.Timeout Julia Lawall
[not found] ` <20240107144227.273e0233@kernel.org>
2024-01-08 6:37 ` Julia Lawall
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.