diff options
author | Jonghwan Choi <jhbird.choi@samsung.com> | 2012-12-24 03:57:42 +0400 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2012-12-24 03:57:42 +0400 |
commit | 9d0554fff9a21d846adcfbd14cfb02e82773162c (patch) | |
tree | 98926538dc47a6e4025c70a65c5493f60ec19a97 /arch/arm/mach-exynos | |
parent | 857d90f7014f4fe0acc49947ad5309174111a4e8 (diff) | |
download | linux-9d0554fff9a21d846adcfbd14cfb02e82773162c.tar.xz |
cpufreq: exynos: Use APLL_FREQ macro for cpu divider value
Signed-off-by: Jonghwan Choi <jhbird.choi@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-exynos')
-rw-r--r-- | arch/arm/mach-exynos/include/mach/cpufreq.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/mach-exynos/include/mach/cpufreq.h b/arch/arm/mach-exynos/include/mach/cpufreq.h index 39f0dc62122b..b5d39dd03b2a 100644 --- a/arch/arm/mach-exynos/include/mach/cpufreq.h +++ b/arch/arm/mach-exynos/include/mach/cpufreq.h @@ -18,6 +18,22 @@ enum cpufreq_level_index { L20, }; +#define APLL_FREQ(f, a0, a1, a2, a3, a4, a5, a6, a7, b0, b1, b2, m, p, s) \ + { \ + .freq = (f) * 1000, \ + .clk_div_cpu0 = ((a0) | (a1) << 4 | (a2) << 8 | (a3) << 12 | \ + (a4) << 16 | (a5) << 20 | (a6) << 24 | (a7) << 28), \ + .clk_div_cpu1 = (b0 << 0 | b1 << 4 | b2 << 8), \ + .mps = ((m) << 16 | (p) << 8 | (s)), \ + } + +struct apll_freq { + unsigned int freq; + u32 clk_div_cpu0; + u32 clk_div_cpu1; + u32 mps; +}; + struct exynos_dvfs_info { unsigned long mpll_freq_khz; unsigned int pll_safe_idx; |