提交 d6b96e47 编写于 作者: M Markus Elfring 提交者: Rafael J. Wysocki

cpufreq: qoriq: Drop memory allocation error messages from qoriq_cpufreq_cpu_init()

Omit extra messages for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.
Signed-off-by: NMarkus Elfring <elfring@users.sourceforge.net>
Acked-by: NViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 d430fb99
...@@ -192,16 +192,12 @@ static int qoriq_cpufreq_cpu_init(struct cpufreq_policy *policy) ...@@ -192,16 +192,12 @@ static int qoriq_cpufreq_cpu_init(struct cpufreq_policy *policy)
count = clk_hw_get_num_parents(hwclk); count = clk_hw_get_num_parents(hwclk);
data->pclk = kcalloc(count, sizeof(struct clk *), GFP_KERNEL); data->pclk = kcalloc(count, sizeof(struct clk *), GFP_KERNEL);
if (!data->pclk) { if (!data->pclk)
pr_err("%s: no memory\n", __func__);
goto err_nomem2; goto err_nomem2;
}
table = kcalloc(count + 1, sizeof(*table), GFP_KERNEL); table = kcalloc(count + 1, sizeof(*table), GFP_KERNEL);
if (!table) { if (!table)
pr_err("%s: no memory\n", __func__);
goto err_pclk; goto err_pclk;
}
for (i = 0; i < count; i++) { for (i = 0; i < count; i++) {
clk = clk_hw_get_parent_by_index(hwclk, i)->clk; clk = clk_hw_get_parent_by_index(hwclk, i)->clk;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册