Fixes scripts/checkpatch.pl warning: WARNING: Possible unnecessary 'out of memory' message Remove it can help us save a bit of memory. Signed-off-by: Zhen Lei <thunder.leizhen@xxxxxxxxxx> --- fs/coredump.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/fs/coredump.c b/fs/coredump.c index 07afb5ddb1c4..a693e9230fb6 100644 --- a/fs/coredump.c +++ b/fs/coredump.c @@ -679,11 +679,8 @@ void do_coredump(const kernel_siginfo_t *siginfo) helper_argv = kmalloc_array(argc + 1, sizeof(*helper_argv), GFP_KERNEL); - if (!helper_argv) { - printk(KERN_WARNING "%s failed to allocate memory\n", - __func__); + if (!helper_argv) goto fail_dropcount; - } for (argi = 0; argi < argc; argi++) helper_argv[argi] = cn.corename + argv[argi]; helper_argv[argi] = NULL; -- 2.25.1