From: Hyeonseong Gil Date: Thu, 13 Apr 2017 06:31:23 +0000 (+0900) Subject: [COMMON] thermal: cpu_cooling: Fix set_cur_temp API X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9614309cd74fc8913ef3958252b4db31a7afe963;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [COMMON] thermal: cpu_cooling: Fix set_cur_temp API Resolved migration conflicts from kernel 4.9 to 4.14. Change-Id: Id1c3cf9b8496a9479cf63eb1599988a589afcf7b Signed-off-by: Hyeonseong Gil --- diff --git a/drivers/thermal/cpu_cooling.c b/drivers/thermal/cpu_cooling.c index 12b4be2c10be..5b780579acdb 100644 --- a/drivers/thermal/cpu_cooling.c +++ b/drivers/thermal/cpu_cooling.c @@ -799,6 +799,7 @@ static struct thermal_cooling_device_ops cpufreq_cooling_ops = { .get_cur_state = cpufreq_get_cur_state, .set_cur_state = cpufreq_set_cur_state, .get_cooling_level = exynos_cpufreq_cooling_get_level, + .set_cur_temp = cpufreq_set_cur_temp, }; static struct thermal_cooling_device_ops cpufreq_power_cooling_ops = { @@ -808,6 +809,7 @@ static struct thermal_cooling_device_ops cpufreq_power_cooling_ops = { .get_requested_power = cpufreq_get_requested_power, .state2power = cpufreq_state2power, .power2state = cpufreq_power2state, + .set_cur_temp = cpufreq_set_cur_temp, }; /* Notifier for cpufreq policy change */ @@ -908,9 +910,6 @@ __cpufreq_cooling_register(struct device_node *np, } cpufreq_cdev->id = ret; - if (cpufreq_cdev->id == 0) - cpufreq_cooling_ops.set_cur_temp = cpufreq_set_cur_temp; - snprintf(dev_name, sizeof(dev_name), "thermal-cpufreq-%d", cpufreq_cdev->id);