diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-07-04 13:21:43 +0200 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-07-04 13:21:43 +0200 |
commit | 5d1191ab6cd82b1347eb1b023a3b1eb36ae74ec9 (patch) | |
tree | 89a3effc70464c52829afed58bcb4b961df048c5 /drivers/cpufreq/davinci-cpufreq.c | |
parent | 742c87bf27d3b715820da6f8a81d6357adbf18f8 (diff) | |
parent | 4a7cb7a96aa32e34777b263fbf372543fb85ddea (diff) | |
download | talos-obmc-linux-5d1191ab6cd82b1347eb1b023a3b1eb36ae74ec9.tar.gz talos-obmc-linux-5d1191ab6cd82b1347eb1b023a3b1eb36ae74ec9.zip |
Merge back earlier cpufreq material for v4.8.
Diffstat (limited to 'drivers/cpufreq/davinci-cpufreq.c')
-rw-r--r-- | drivers/cpufreq/davinci-cpufreq.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/drivers/cpufreq/davinci-cpufreq.c b/drivers/cpufreq/davinci-cpufreq.c index 7e336d20c184..b95a872800ec 100644 --- a/drivers/cpufreq/davinci-cpufreq.c +++ b/drivers/cpufreq/davinci-cpufreq.c @@ -38,26 +38,6 @@ struct davinci_cpufreq { }; static struct davinci_cpufreq cpufreq; -static int davinci_verify_speed(struct cpufreq_policy *policy) -{ - struct davinci_cpufreq_config *pdata = cpufreq.dev->platform_data; - struct cpufreq_frequency_table *freq_table = pdata->freq_table; - struct clk *armclk = cpufreq.armclk; - - if (freq_table) - return cpufreq_frequency_table_verify(policy, freq_table); - - if (policy->cpu) - return -EINVAL; - - cpufreq_verify_within_cpu_limits(policy); - policy->min = clk_round_rate(armclk, policy->min * 1000) / 1000; - policy->max = clk_round_rate(armclk, policy->max * 1000) / 1000; - cpufreq_verify_within_limits(policy, policy->cpuinfo.min_freq, - policy->cpuinfo.max_freq); - return 0; -} - static int davinci_target(struct cpufreq_policy *policy, unsigned int idx) { struct davinci_cpufreq_config *pdata = cpufreq.dev->platform_data; @@ -121,7 +101,7 @@ static int davinci_cpu_init(struct cpufreq_policy *policy) static struct cpufreq_driver davinci_driver = { .flags = CPUFREQ_STICKY | CPUFREQ_NEED_INITIAL_FREQ_CHECK, - .verify = davinci_verify_speed, + .verify = cpufreq_generic_frequency_table_verify, .target_index = davinci_target, .get = cpufreq_generic_get, .init = davinci_cpu_init, |