Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 116decb7 authored by Sachin Kamat's avatar Sachin Kamat Committed by Rafael J. Wysocki
Browse files

cpufreq: exynos5440: Fix potential NULL pointer dereference



If 'dvfs_info' is NULL (due to devm_kzalloc failure) the failure
error message would try to dereference it. Use 'pdev' instead.

Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Acked-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 26ca8694
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -457,7 +457,7 @@ static int exynos_cpufreq_probe(struct platform_device *pdev)
	opp_free_cpufreq_table(dvfs_info->dev, &dvfs_info->freq_table);
err_put_node:
	of_node_put(np);
	dev_err(dvfs_info->dev, "%s: failed initialization\n", __func__);
	dev_err(&pdev->dev, "%s: failed initialization\n", __func__);
	return ret;
}