summaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq
diff options
context:
space:
mode:
authorInderpal Singh <inderpal.singh@linaro.org>2013-01-18 11:07:33 -0800
committerKukjin Kim <kgene.kim@samsung.com>2013-01-18 11:08:25 -0800
commit1298271b03be167f455303cd9146ba1b771028d8 (patch)
tree527948e71fa3b2b44435be3ab931e42b9668c6d7 /drivers/cpufreq
parent94aa44090eda62320ce0dfd8c52ac21e787215a2 (diff)
downloadop-kernel-dev-1298271b03be167f455303cd9146ba1b771028d8.zip
op-kernel-dev-1298271b03be167f455303cd9146ba1b771028d8.tar.gz
cpufreq: exynos: Show list of available frequencies
Add freq_attr attribute to show list of available frequencies. Signed-off-by: Donggeun Kim <dg77.kim@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: KyungMin Park <kyungmin.park@samsung.com> Signed-off-by: Inderpal Singh <inderpal.singh@linaro.org> Reviewed-by: Amit Daniel Kachhap<amit.daniel@samsung.com> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'drivers/cpufreq')
-rw-r--r--drivers/cpufreq/exynos-cpufreq.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/cpufreq/exynos-cpufreq.c b/drivers/cpufreq/exynos-cpufreq.c
index 232208c..2183e9a 100644
--- a/drivers/cpufreq/exynos-cpufreq.c
+++ b/drivers/cpufreq/exynos-cpufreq.c
@@ -268,13 +268,26 @@ static int exynos_cpufreq_cpu_init(struct cpufreq_policy *policy)
return cpufreq_frequency_table_cpuinfo(policy, exynos_info->freq_table);
}
+static int exynos_cpufreq_cpu_exit(struct cpufreq_policy *policy)
+{
+ cpufreq_frequency_table_put_attr(policy->cpu);
+ return 0;
+}
+
+static struct freq_attr *exynos_cpufreq_attr[] = {
+ &cpufreq_freq_attr_scaling_available_freqs,
+ NULL,
+};
+
static struct cpufreq_driver exynos_driver = {
.flags = CPUFREQ_STICKY,
.verify = exynos_verify_speed,
.target = exynos_target,
.get = exynos_getspeed,
.init = exynos_cpufreq_cpu_init,
+ .exit = exynos_cpufreq_cpu_exit,
.name = "exynos_cpufreq",
+ .attr = exynos_cpufreq_attr,
#ifdef CONFIG_PM
.suspend = exynos_cpufreq_suspend,
.resume = exynos_cpufreq_resume,
OpenPOWER on IntegriCloud