Skip to contentSkip to conversation

clk: samsung: Delete an error message for a failed memory allocation in exynos_register_cpu_clock()

PATCH In review SF Markus Elfring 2 participants 2 messages Sep 27, 2017

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 clk: samsung: Delete an error message for a failed memory allocation in exynos_register_cpu_clock()

From: Markus Elfring <[email protected]>
Date: Wed, 27 Sep 2017 15:46:53 +0200

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

---
 drivers/clk/samsung/clk-cpu.c | 2 --
 1 file changed, 2 deletions(-)
drivers/clk/samsung/clk-cpu.c +0 -2
index 6686e8ba61f9..d2c99d8916b8 100644
@@ -457,8 +457,6 @@ int __init exynos_register_cpu_clock(struct samsung_clk_provider *ctx,
 
 	cpuclk->cfg = kmemdup(cfg, sizeof(*cfg) * num_cfgs, GFP_KERNEL);
 	if (!cpuclk->cfg) {
-		pr_err("%s: could not allocate memory for cpuclk data\n",
-				__func__);
 		ret = -ENOMEM;
 		goto unregister_clk_nb;
 	}
Signature · 1 line
2.14.1
#1 lore raw
Quoted 8 lines · SF Markus Elfring

From: Markus Elfring <[email protected]>
Date: Wed, 27 Sep 2017 15:46:53 +0200

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

Applied with summary line shortened to
"clk: samsung: Delete a memory allocation error message in clk-cpu.c", thanks.

Quoted 17 lines
---
 drivers/clk/samsung/clk-cpu.c | 2 --
 1 file changed, 2 deletions(-)
drivers/clk/samsung/clk-cpu.c +0 -2
index 6686e8ba61f9..d2c99d8916b8 100644
@@ -457,8 +457,6 @@ int __init exynos_register_cpu_clock(struct samsung_clk_provider *ctx,
 
 	cpuclk->cfg = kmemdup(cfg, sizeof(*cfg) * num_cfgs, GFP_KERNEL);
 	if (!cpuclk->cfg) {
-		pr_err("%s: could not allocate memory for cpuclk data\n",
-				__func__);
 		ret = -ENOMEM;
 		goto unregister_clk_nb;
 	}