summaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq/exynos5440-cpufreq.c
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2013-10-03 20:28:06 +0530
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-10-16 00:50:25 +0200
commiteea6181ed2904f379497918a032588f5e74566e4 (patch)
treede1953b551912147e952f073e35676d096000499 /drivers/cpufreq/exynos5440-cpufreq.c
parent06494eb783cf34fa1d67b77fa597b656b6ad07fe (diff)
downloadblackbird-op-linux-eea6181ed2904f379497918a032588f5e74566e4.tar.gz
blackbird-op-linux-eea6181ed2904f379497918a032588f5e74566e4.zip
cpufreq: exynos: Use generic cpufreq routines
Most of the CPUFreq drivers do similar things in .exit() and .verify() routines and .attr. So its better if we have generic routines for them which can be used by cpufreq drivers then. This patch uses these generic routines in the exynos driver. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-By: Amit Daniel Kachhap <amit.daniel@samsung.com> Acked-by: Kukjin Kim <kgene.kim@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/cpufreq/exynos5440-cpufreq.c')
-rw-r--r--drivers/cpufreq/exynos5440-cpufreq.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/drivers/cpufreq/exynos5440-cpufreq.c b/drivers/cpufreq/exynos5440-cpufreq.c
index 24df155f871e..bce6f7442aa5 100644
--- a/drivers/cpufreq/exynos5440-cpufreq.c
+++ b/drivers/cpufreq/exynos5440-cpufreq.c
@@ -209,12 +209,6 @@ static void exynos_enable_dvfs(void)
dvfs_info->base + XMU_DVFS_CTRL);
}
-static int exynos_verify_speed(struct cpufreq_policy *policy)
-{
- return cpufreq_frequency_table_verify(policy,
- dvfs_info->freq_table);
-}
-
static unsigned int exynos_getspeed(unsigned int cpu)
{
return dvfs_info->cur_frequency;
@@ -339,19 +333,13 @@ static int exynos_cpufreq_cpu_init(struct cpufreq_policy *policy)
return 0;
}
-static int exynos_cpufreq_cpu_exit(struct cpufreq_policy *policy)
-{
- cpufreq_frequency_table_put_attr(policy->cpu);
- return 0;
-}
-
static struct cpufreq_driver exynos_driver = {
.flags = CPUFREQ_STICKY,
- .verify = exynos_verify_speed,
+ .verify = cpufreq_generic_frequency_table_verify,
.target = exynos_target,
.get = exynos_getspeed,
.init = exynos_cpufreq_cpu_init,
- .exit = exynos_cpufreq_cpu_exit,
+ .exit = cpufreq_generic_exit,
.name = CPUFREQ_NAME,
};
OpenPOWER on IntegriCloud