From: zwl Date: Thu, 8 May 2014 12:55:36 +0000 (+0800) Subject: rk fb: fix boot image disp err for hdmi X-Git-Tag: firefly_0821_release~5323 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=27a285c03362642d404e5ef6ebd48c20ec5470dc;p=firefly-linux-kernel-4.4.55.git rk fb: fix boot image disp err for hdmi --- diff --git a/drivers/video/rockchip/hdmi/chips/rk3288/rk3288_hdmi_hw.c b/drivers/video/rockchip/hdmi/chips/rk3288/rk3288_hdmi_hw.c index a15450039cb8..b34c973fedf2 100644 --- a/drivers/video/rockchip/hdmi/chips/rk3288/rk3288_hdmi_hw.c +++ b/drivers/video/rockchip/hdmi/chips/rk3288/rk3288_hdmi_hw.c @@ -67,8 +67,7 @@ static void rk3288_hdmi_set_pwr_mode(struct hdmi *hdmi_drv, int mode) hdmi_writel(hdmi_dev, MC_CLKDIS, 0x00); break; case LOWER_PWR: - //hdmi_msk_reg(hdmi_dev, MC_CLKDIS, m_AUDCLK_DISABLE | m_PREPCLK_DISABLE | m_TMDSCLK_DISABLE | m_PIXELCLK_DISABLE, - //v_AUDCLK_DISABLE(1) | v_PREPCLK_DISABLE(1) | v_TMDSCLK_DISABLE(1) | v_PIXELCLK_DISABLE(1)); + hdmi_writel(hdmi_dev, MC_CLKDIS, 0xff); hdmi_msk_reg(hdmi_dev, PHY_CONF0, m_TMDS_EN | m_TXPWRON_SIG | m_ENHPD_RXSENSE_SIG, v_TMDS_EN(0) | v_TXPWRON_SIG(0) | v_ENHPD_RXSENSE_SIG(1)); break; @@ -260,7 +259,6 @@ static int rk3288_hdmi_video_frameComposer(struct hdmi *hdmi_drv, struct hdmi_vi hdmi_drv->tmdsclk = mode->pixclock; break; } - rk3288_hdmi_config_phy(hdmi_drv, vpara->pixel_repet, vpara->color_depth); hdmi_msk_reg(hdmi_dev, A_HDCPCFG0, m_ENCRYPT_BYPASS | m_HDMI_DVI, v_ENCRYPT_BYPASS(1) | v_HDMI_DVI(vpara->output_mode)); //cfg to bypass hdcp data encrypt @@ -939,7 +937,8 @@ int rk3288_hdmi_config_video(struct hdmi *hdmi_drv, struct hdmi_video_para *vpar hdmi_dbg(hdmi_drv->dev, "[%s] sucess output DVI.\n", __FUNCTION__); } - //rk3288_hdmi_control_output(hdmi_drv, 0); + rk3288_hdmi_set_pwr_mode(hdmi_drv, NORMAL); + rk3288_hdmi_config_phy(hdmi_drv, vpara->pixel_repet, vpara->color_depth); return 0; } diff --git a/drivers/video/rockchip/rk_fb.c b/drivers/video/rockchip/rk_fb.c index 272543bfa89b..809a1b78df6d 100755 --- a/drivers/video/rockchip/rk_fb.c +++ b/drivers/video/rockchip/rk_fb.c @@ -937,6 +937,9 @@ static int rk_fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *info extend_win->area[0].y_offset = win->area[0].y_offset; #if defined(CONFIG_FB_ROTATE) || !defined(CONFIG_THREE_FB_BUFFER) rk_fb_rotate(extend_info, info, win->area[0].y_offset); + #else + extend_win->area[0].smem_start = win->area[0].smem_start; + extend_win->area[0].cbr_start = win->area[0].cbr_start; #endif extend_dev_drv->ops->pan_display(extend_dev_drv, extend_win_id); } @@ -2262,10 +2265,7 @@ if (rk_fb->disp_mode != DUAL) { extend_win->area[0].xsize = extend_dev_drv->cur_screen->xsize; extend_win->area[0].ysize = extend_dev_drv->cur_screen->ysize; } - #if !defined(CONFIG_FB_ROTATE) && defined(CONFIG_THREE_FB_BUFFER) - extend_win->area[0].smem_start = win->area[0].smem_start; - extend_win->area[0].cbr_start = win->area[0].cbr_start; - #endif + extend_win->area[0].state = 1; extend_win->area_num = 1; extend_win->alpha_en = 0;