Fix built in thermald

file:39ef96af76dbedbe491a92b5dca152ac44aee1b8 -> file:55439672b00a76cd29caea8514e0ffe61066d4f4
--- a/drivers/thermal/msm_thermal.c
+++ b/drivers/thermal/msm_thermal.c
@@ -101,14 +101,21 @@ static int update_cpu_max_freq(struct cp
if (!cpu_policy)
return -EINVAL;
- cpufreq_verify_within_limits(cpu_policy,
- cpu_policy->min, max_freq);
+ cpufreq_verify_within_limits(cpu_policy, cpu_policy->min, max_freq);
+
+#ifdef CONFIG_SEC_DVFS
+ if (max_freq >= MAX_FREQ_LIMIT)
+ cpufreq_set_limit_defered(USER_MAX_STOP, max_freq);
+ else if (max_freq >= MIN_FREQ_LIMIT)
+ cpufreq_set_limit_defered(USER_MAX_START, max_freq);
+#else
cpu_policy->user_policy.max = max_freq;
ret = cpufreq_update_policy(cpu);
if (!ret)
pr_debug("msm_thermal: Limiting core%d max frequency to %d\n",
cpu, max_freq);
+#endif
return ret;
}