From dd633aeaf03ff5da8dce9d5182947f6c7bd92d3d Mon Sep 17 00:00:00 2001 From: chenxing Date: Fri, 19 Jul 2013 15:04:32 +0800 Subject: [PATCH] rk3188: -t: fix ddr volt too low --- arch/arm/mach-rk30/board-rk3168-tb.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-rk30/board-rk3168-tb.c b/arch/arm/mach-rk30/board-rk3168-tb.c index 824b46b67d63..2eff6bb1a1cf 100755 --- a/arch/arm/mach-rk30/board-rk3168-tb.c +++ b/arch/arm/mach-rk30/board-rk3168-tb.c @@ -52,6 +52,7 @@ #ifdef CONFIG_MFD_RT5025 #include #endif +#include #ifdef CONFIG_CW2015_BATTERY #include @@ -2664,6 +2665,12 @@ static struct cpufreq_frequency_table dvfs_ddr_table_volt_level0[] = { {.frequency = CPUFREQ_TABLE_END}, }; +static struct cpufreq_frequency_table dvfs_ddr_table_t[] = { + {.frequency = 200 * 1000 + DDR_FREQ_SUSPEND, .index = 950 * 1000}, + {.frequency = 460 * 1000 + DDR_FREQ_NORMAL, .index = 1150 * 1000}, + {.frequency = CPUFREQ_TABLE_END}, +}; + //if you board is good for volt quality,select dvfs_arm_table_volt_level0 #define dvfs_arm_table dvfs_arm_table_volt_level1 #define dvfs_gpu_table dvfs_gpu_table_volt_level1 @@ -2731,7 +2738,11 @@ void __init board_clock_init(void) //dvfs_set_arm_logic_volt(dvfs_cpu_logic_table, cpu_dvfs_table, dep_cpu2core_table); dvfs_set_freq_volt_table(clk_get(NULL, "cpu"), dvfs_arm_table); dvfs_set_freq_volt_table(clk_get(NULL, "gpu"), dvfs_gpu_table); - dvfs_set_freq_volt_table(clk_get(NULL, "ddr"), dvfs_ddr_table); + if (rk_pll_flag() == 0) + dvfs_set_freq_volt_table(clk_get(NULL, "ddr"), dvfs_ddr_table); + else + dvfs_set_freq_volt_table(clk_get(NULL, "ddr"), dvfs_ddr_table_t); + } MACHINE_START(RK30, "RK30board") -- 2.34.1