cpufreq: acme: change API for cooling device registration
authorSoohyun Kim <soohyuni.kim@samsung.com>
Mon, 22 Jan 2018 10:56:58 +0000 (19:56 +0900)
committerChungwoo Park <cww.park@samsung.com>
Mon, 21 May 2018 08:30:36 +0000 (17:30 +0900)
Change-Id: Ib52c8ca4209ef88ee85dcb3094d192899e4a2f9a
Signed-off-by: Soohyun Kim <soohyuni.kim@samsung.com>
drivers/cpufreq/exynos-acme.c

index 41d209af4abfca0f080545996403eef874303cfd..4f6991d9b9b8113215ecf94a39598facb48cffba 100644 (file)
@@ -1648,9 +1648,11 @@ static int __init exynos_cpufreq_init(void)
         * Update frequency as soon as domain is enabled.
         */
        list_for_each_entry(domain, &domains, list) {
+               struct cpufreq_policy *policy = cpufreq_cpu_get_raw(cpumask_first(&domain->cpus));
                set_policy(domain);
                enable_domain(domain);
-               exynos_cpufreq_cooling_register(domain->dn, &domain->cpus);
+               if (!policy)
+                       cpufreq_cooling_register(policy);
 
                set_boot_qos(domain);
        }