From: 陈亮 Date: Fri, 4 Jul 2014 03:58:01 +0000 (-0700) Subject: change ddrfreq directly in ddr_init() since lcdc is not init X-Git-Tag: firefly_0821_release~4999 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=7f889b469708387dfd61dc8d5627b4e7555f02bf;p=firefly-linux-kernel-4.4.55.git change ddrfreq directly in ddr_init() since lcdc is not init Signed-off-by: 陈亮 --- diff --git a/arch/arm/mach-rockchip/ddr_rk32.c b/arch/arm/mach-rockchip/ddr_rk32.c index 9381089806a3..27367cec5b72 100755 --- a/arch/arm/mach-rockchip/ddr_rk32.c +++ b/arch/arm/mach-rockchip/ddr_rk32.c @@ -4025,6 +4025,9 @@ static int _ddr_change_freq(uint32 nMHz) { ddr_freq_t.screen_ft_us = rk_fb_get_prmry_screen_ft(); ddr_freq_t.t0 = rk_fb_get_prmry_screen_framedone_t(); + if (!ddr_freq_t.screen_ft_us) + return __ddr_change_freq(nMHz, ddr_freq_t); + tmp = cpu_clock(0) - ddr_freq_t.t0; do_div(tmp, 1000); pass_t = tmp;