diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2017-06-03 21:34:48 +0200 |
---|---|---|
committer | Robert Jarzmik <robert.jarzmik@free.fr> | 2017-06-14 08:32:21 +0200 |
commit | c276557de3087ef67ad1aec4222f9f8b1d005f80 (patch) | |
tree | c924e215229b99bbb29e14f58b3bf75dfe2c1a2f /arch | |
parent | 7ade445c26269d5af6c34ee50be97d54a3992d02 (diff) |
ARM: pxa: Delete an error message for a failed memory allocation in pxa_pm_init()
Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Link: http://events.linuxfoundation.org/sites/events/files/slides/LCJ16-Refactor_Strings-WSang_0.pdf
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-pxa/pm.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/arm/mach-pxa/pm.c b/arch/arm/mach-pxa/pm.c index e7450fb49d24..f2237f471750 100644 --- a/arch/arm/mach-pxa/pm.c +++ b/arch/arm/mach-pxa/pm.c @@ -107,10 +107,8 @@ static int __init pxa_pm_init(void) sleep_save = kmalloc_array(pxa_cpu_pm_fns->save_count, sizeof(*sleep_save), GFP_KERNEL); - if (!sleep_save) { - printk(KERN_ERR "failed to alloc memory for pm save\n"); + if (!sleep_save) return -ENOMEM; - } suspend_set_ops(&pxa_pm_ops); return 0; |