video: add config option to skip framebuffer clear

The use-case is that the thing that loaded u-boot already put a splash
image on screen.  And we want to preserve that until grub boot menu
takes over.

Signed-off-by: Rob Clark <robdclark@gmail.com>
This commit is contained in:
Rob Clark 2017-08-03 12:47:01 -04:00 committed by Anatolij Gustschin
parent 971d7e6424
commit 8ef0535250
3 changed files with 13 additions and 2 deletions

View File

@ -119,6 +119,14 @@ config SYS_WHITE_ON_BLACK
better in low-light situations or to reduce eye strain in some
cases.
config NO_FB_CLEAR
bool "Skip framebuffer clear"
help
If firmware (whatever loads u-boot) has already put a splash image
on screen, you might want to preserve it until whatever u-boot
loads takes over the screen. This, for example, can be used to
keep splash image on screen until grub graphical boot menu starts.
source "drivers/video/fonts/Kconfig"
config VIDCONSOLE_AS_LCD

View File

@ -2081,7 +2081,8 @@ static int cfg_video_init(void)
}
eorx = fgx ^ bgx;
video_clear();
if (!CONFIG_IS_ENABLED(NO_FB_CLEAR))
video_clear();
#ifdef CONFIG_VIDEO_LOGO
/* Plot the logo and get start point of console */

View File

@ -199,7 +199,9 @@ static int video_post_probe(struct udevice *dev)
#else
priv->colour_bg = 0xffffff;
#endif
video_clear(dev);
if (!CONFIG_IS_ENABLED(NO_FB_CLEAR))
video_clear(dev);
/*
* Create a text console device. For now we always do this, although