From: Viresh Kumar Date: Mon, 16 Sep 2013 13:26:05 +0000 (+0530) Subject: cpufreq: s3cx4xx: call cpufreq_frequency_table_get_attr() X-Git-Tag: v3.13-rc3~6^2~1^3~23^2~157 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5c40e052bb04381302c748497076b5b4526ed6cb;p=platform%2Fkernel%2Flinux-exynos.git cpufreq: s3cx4xx: call cpufreq_frequency_table_get_attr() This exposes frequency table of driver to cpufreq core and is required for core to guess what the index for a target frequency is, when it calls cpufreq_frequency_table_target(). And so this driver needs to expose it. Cc: Kukjin Kim Signed-off-by: Viresh Kumar Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/cpufreq/s3c24xx-cpufreq.c b/drivers/cpufreq/s3c24xx-cpufreq.c index b0f343f..f2c872c 100644 --- a/drivers/cpufreq/s3c24xx-cpufreq.c +++ b/drivers/cpufreq/s3c24xx-cpufreq.c @@ -386,8 +386,10 @@ static int s3c_cpufreq_init(struct cpufreq_policy *policy) /* feed the latency information from the cpu driver */ policy->cpuinfo.transition_latency = cpu_cur.info->latency; - if (ftab) + if (ftab) { cpufreq_frequency_table_cpuinfo(policy, ftab); + cpufreq_frequency_table_get_attr(ftab, policy->cpu); + } return 0; } diff --git a/drivers/cpufreq/s3c64xx-cpufreq.c b/drivers/cpufreq/s3c64xx-cpufreq.c index 8a72b0c..9024043 100644 --- a/drivers/cpufreq/s3c64xx-cpufreq.c +++ b/drivers/cpufreq/s3c64xx-cpufreq.c @@ -257,6 +257,9 @@ static int s3c64xx_cpufreq_driver_init(struct cpufreq_policy *policy) ret); regulator_put(vddarm); clk_put(armclk); + } else { + cpufreq_frequency_table_get_attr(s3c64xx_freq_table, + policy->cpu); } return ret;