void __init board_clock_init(void)
{
- rk30_clock_data_init(periph_pll_297mhz, codec_pll_360mhz, max_i2s_12288khz);
+ rk30_clock_data_init(periph_pll_default, codec_pll_default, RK30_CLOCKS_DEFAULT_FLAGS);
dvfs_set_freq_volt_table(clk_get(NULL, "cpu"), cpu_dvfs_table);
}
_PLL_SET_CLKS(504000, 1, 21, 1),
_PLL_SET_CLKS(552000, 1, 23, 1),
_PLL_SET_CLKS(600000, 1, 25, 1),
- _PLL_SET_CLKS( 0, 1, 23, 1),
+ _PLL_SET_CLKS(798000, 4, 133, 1),
+ _PLL_SET_CLKS( 0, 4, 133, 1),
};
static struct _pll_data cpll_data=SET_PLL_DATA(CPLL_ID,(void *)cpll_clks);
static struct clk codec_pll_clk = {
clk_set_rate_nolock(&aclk_vepu, 300*MHZ);
clk_set_rate_nolock(&aclk_vdpu, 300*MHZ);
-
//gpu auto sel
//clk_set_parent_nolock(&clk_gpu, &general_pll_clk);
}
/* if up the voltage*/\r
if (volt_old < volt_new) {\r
if(dvfs_clk->vd->regulator&&dvfs_regulator_set_voltage(dvfs_clk->vd->regulator,volt_new, volt_new) < 0) {\r
- DVFS_ERR("set voltage err\n");\r
+ DVFS_ERR("set voltage err up\n");\r
return -1;\r
}\r
dvfs_clk->vd->cur_volt = volt_new;\r
/* if down the voltage */\r
if (volt_old > volt_new) {\r
if(dvfs_clk->vd->regulator&&dvfs_regulator_set_voltage(dvfs_clk->vd->regulator, volt_new, volt_new) < 0) {\r
- DVFS_ERR("set voltage err\n");\r
+ DVFS_ERR("set voltage err dn\n");\r
return -1;\r
}\r
dvfs_clk->vd->cur_volt = volt_new;\r
codec_pll_504mhz = 504000000,
codec_pll_552mhz = 552000000, /* for HDMI */
codec_pll_600mhz = 600000000,
- codec_pll_default = codec_pll_360mhz,
+ codec_pll_798mhz = 798000000,
+ codec_pll_default = codec_pll_798mhz,
};
//has extern 27mhz
#define CLK_FLG_EXT_27MHZ (1<<0)
#define CLK_FLG_MAX_I2S_49152KHZ (1<<4)
#define max_i2s_12288khz (CLK_FLG_MAX_I2S_12288KHZ/*|CLK_FLG_EXT_27MHZ*/)
+#define RK30_CLOCKS_DEFAULT_FLAGS (CLK_FLG_MAX_I2S_12288KHZ/*|CLK_FLG_EXT_27MHZ*/)
#endif
static u64 hispeed_freq;
/* Go to hi speed when CPU load at or above this value. */
-#ifdef CONFIG_ARCH_RK29
+#ifdef CONFIG_PLAT_RK
#define DEFAULT_GO_HISPEED_LOAD 80
#else
#define DEFAULT_GO_HISPEED_LOAD 95
new_freq = pcpu->freq_table[index].frequency;
-#ifdef CONFIG_ARCH_RK29
+#ifdef CONFIG_PLAT_RK
pcpu->target_freq = pcpu->policy->cur;
#endif
if (pcpu->target_freq == new_freq)
}
if (!hispeed_freq)
-#ifdef CONFIG_ARCH_RK29
+#ifdef CONFIG_PLAT_RK
hispeed_freq = 816000;
#else
hispeed_freq = policy->max;