Staging: most: Do not print message if kzalloc() failed.
Subsystems (2)
PATCH 1/1 Staging: most: Do not print message if kzalloc() failed.
Do not print message if kzalloc() failed. kzalloc() has its own messages. So no need to add extra one.
--- drivers/staging/most/mostcore/core.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/most/mostcore/core.c +0 -1
@@ -1259,7 +1259,6 @@ static int arm_mbo_chain(struct most_c_obj *c, int dir,for (i =0 ; i < c->cfg.num_buffers; i++) { mbo =kzalloc (sizeof (*mbo),GFP_KERNEL );if (!mbo) { -pr_info ("WARN: Allocation of MBO failed.\n" ); retval = i; goto _exit; }
Signature · 1 line
1.8.3.4
Quoted 2 lines · Sandhya Bankar
Do not print message if
kzalloc()failed.kzalloc()has its own messages. So no need to add extra one.
You could try to generalize this using Coccinelle.
Something that could be useful:
constant char[] c;
matches an explicit string.
julia
Quoted 28 lines
Signed-off-by Sandhya Bankar <[email protected]>--- drivers/staging/most/mostcore/core.c | 1 - 1 file changed, 1 deletion(-)drivers/staging/most/mostcore/core.c +0
-2@@ -1259,7 +1259,6 @@ static int arm_mbo_chain(struct most_c_obj *c, int dir,for (i =0 ; i < c->cfg.num_buffers; i++) { mbo =kzalloc (sizeof (*mbo),GFP_KERNEL );if (!mbo) { -pr_info ("WARN: Allocation of MBO failed.\n" ); retval = i; goto _exit; } --1.8.3.4
--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20160221050205.GA3014%40sandhya.
For more options, visit https://groups.google.com/d/optout.