media: staging: atomisp: cleanup out of memory messages
Logging of explicit out of memory messages is redundant since memory allocation
failures produce a backtrace.
Done with the help of the following cocci script:
@@
expression ex, ret;
statement s;
constant char[] c;
constant err;
identifier f, l;
@@
ex =
\(kmalloc\|kmalloc_array\|kzalloc\|kcalloc\|kmem_cache_alloc\|kmem_cache_zalloc\|
kmem_cache_alloc_node\|kmalloc_node\|kzalloc_node\|devm_kzalloc\)(...)
... when != ex
if (
(
!ex
|
unlikely(!ex)
)
)
- {
- f(..., c, ...);
(
return ex;
|
return;
|
return err;
|
goto l;
)
- }
else s
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Showing
Please register or sign in to comment