diff options
author | Fancy Fang <chen.fang@nxp.com> | 2019-04-12 15:42:50 +0800 |
---|---|---|
committer | Fancy Fang <chen.fang@nxp.com> | 2019-04-12 19:33:16 +0800 |
commit | 7a0078775fb8681c4e12e434e8a4aba15e467e42 (patch) | |
tree | 41b147c311dbf4be3e60eecd1f8c096c214c6828 /drivers/video | |
parent | 6c6c6d774aa9d982f8599492baaf12b2544c3e16 (diff) |
MLK-21380 video: fbdev: mxsfb: fix resume timing for overlay fb
The overlay fb can only be enabled when the LCDIF is not in
running, otherwise overlay display may look like image shift.
So during the system resume procedure, the overlay fb should
be resumed before mxsfb unblank.
Signed-off-by: Fancy Fang <chen.fang@nxp.com>
(cherry picked from commit f39662a3a38a2da082d55a006e634766cc85e347)
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/fbdev/mxsfb.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/video/fbdev/mxsfb.c b/drivers/video/fbdev/mxsfb.c index 51740a3f4de5..f4294b355d21 100644 --- a/drivers/video/fbdev/mxsfb.c +++ b/drivers/video/fbdev/mxsfb.c @@ -4,7 +4,7 @@ * This code is based on: * Author: Vitaly Wool <vital@embeddedalley.com> * - * Copyright 2017 NXP + * Copyright 2017-2019 NXP * Copyright 2008-2015 Freescale Semiconductor, Inc. All Rights Reserved. * Copyright 2008 Embedded Alley Solutions, Inc All Rights Reserved. * @@ -2149,6 +2149,9 @@ static void mxsfb_overlay_resume(struct mxsfb_info *fbi) clk_enable_disp_axi(fbi); } + /* Pull LCDIF out of reset */ + writel(0xc0000000, fbi->base + LCDC_CTRL + REG_CLR); + writel(saved_as_ctrl, fbi->base + LCDC_AS_CTRL); writel(saved_as_next_buf, fbi->base + LCDC_AS_NEXT_BUF); @@ -2462,9 +2465,9 @@ static int mxsfb_resume(struct device *pdev) pinctrl_pm_select_default_state(pdev); console_lock(); + mxsfb_overlay_resume(host); mxsfb_blank(host->restore_blank, fb_info); fb_set_suspend(fb_info, 0); - mxsfb_overlay_resume(host); console_unlock(); return 0; |