summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorAlex Frid <afrid@nvidia.com>2012-02-06 14:45:06 -0800
committerVarun Colbert <vcolbert@nvidia.com>2012-03-14 16:36:24 -0700
commitd72369393c5997afa3a92e4aaad840c157c9c257 (patch)
treec2c4ea9b9ade08f4d9180fbab57714b9ac641377 /arch
parent769ea5a0361eaba66047f9c9a1b5664659d03cf5 (diff)
ARM: tegra: clock: Update Tegra3 CPU suspend rate
Set Tegra3 CPU suspend entry rate to maximum LP mode rate - speed up suspend, and still allow to switch to LP CPU mode on suspend entry. Bug 946301 Signed-off-by: Alex Frid <afrid@nvidia.com> (cherry picked from commit 5e7fa33ebcb5602093f9bf86e37f0478e389c633) Change-Id: I5df4305579a9992817bae168925c4bb208934481 Reviewed-on: http://git-master/r/89351 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-tegra/tegra3_clocks.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/arch/arm/mach-tegra/tegra3_clocks.c b/arch/arm/mach-tegra/tegra3_clocks.c
index 99878dd6fb3a..bbcd9f5738ef 100644
--- a/arch/arm/mach-tegra/tegra3_clocks.c
+++ b/arch/arm/mach-tegra/tegra3_clocks.c
@@ -4618,21 +4618,22 @@ static struct cpufreq_frequency_table freq_table_1p7GHz[] = {
};
static struct tegra_cpufreq_table_data cpufreq_tables[] = {
- { freq_table_300MHz, 0, 1 },
- { freq_table_1p0GHz, 2, 8, 3},
- { freq_table_1p3GHz, 2, 10, 3},
- { freq_table_1p4GHz, 2, 11, 3},
- { freq_table_1p5GHz, 2, 12, 3},
- { freq_table_1p7GHz, 2, 12, 3},
+ { freq_table_300MHz, 0, 1 },
+ { freq_table_1p0GHz, 2, 8 },
+ { freq_table_1p3GHz, 2, 10 },
+ { freq_table_1p4GHz, 2, 11 },
+ { freq_table_1p5GHz, 2, 12 },
+ { freq_table_1p7GHz, 2, 12 },
};
static int clip_cpu_rate_limits(
- struct cpufreq_frequency_table *freq_table,
+ struct tegra_cpufreq_table_data *data,
struct cpufreq_policy *policy,
struct clk *cpu_clk_g,
struct clk *cpu_clk_lp)
{
int idx, ret;
+ struct cpufreq_frequency_table *freq_table = data->freq_table;
/* clip CPU G mode maximum frequency to table entry */
ret = cpufreq_frequency_table_target(policy, freq_table,
@@ -4660,6 +4661,7 @@ static int clip_cpu_rate_limits(
}
cpu_clk_lp->max_rate = freq_table[idx].frequency * 1000;
cpu_clk_g->min_rate = freq_table[idx-1].frequency * 1000;
+ data->suspend_index = idx;
return 0;
}
@@ -4687,7 +4689,7 @@ struct tegra_cpufreq_table_data *tegra_cpufreq_table_get(void)
if (!ret) {
if ((policy.max * 1000) == selection_rate) {
ret = clip_cpu_rate_limits(
- cpufreq_tables[i].freq_table,
+ &cpufreq_tables[i],
&policy, cpu_clk_g, cpu_clk_lp);
if (!ret)
return &cpufreq_tables[i];