From: Rob Clark <robdclark@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 3/3] video: add config option to skip framebuffer clear
Date: Fri, 21 Jul 2017 15:07:10 -0400 [thread overview]
Message-ID: <20170721190710.7758-4-robdclark@gmail.com> (raw)
In-Reply-To: <20170721190710.7758-1-robdclark@gmail.com>
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>
---
drivers/video/Kconfig | 8 ++++++++
drivers/video/cfb_console.c | 3 ++-
drivers/video/video-uclass.c | 4 +++-
3 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index 8eb0359231..7b56b20344 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -98,6 +98,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-boots
+ 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
diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c
index f54802052e..85fa5b0cae 100644
--- a/drivers/video/cfb_console.c
+++ b/drivers/video/cfb_console.c
@@ -2091,7 +2091,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 */
diff --git a/drivers/video/video-uclass.c b/drivers/video/video-uclass.c
index 3036e3a1f2..dfa39b0d1b 100644
--- a/drivers/video/video-uclass.c
+++ b/drivers/video/video-uclass.c
@@ -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
--
2.13.0
next prev parent reply other threads:[~2017-07-21 19:07 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-21 19:07 [U-Boot] [PATCH 0/3] video patches Rob Clark
2017-07-21 19:07 ` [U-Boot] [PATCH 1/3] dm: core: also parse chosen node Rob Clark
2017-07-21 19:07 ` [U-Boot] [PATCH 2/3] video: simplefb Rob Clark
2017-07-21 19:07 ` Rob Clark [this message]
-- strict thread matches above, loose matches on Subject: below --
2017-08-03 16:46 [U-Boot] [PATCH 1/3] dm: core: also parse chosen node Rob Clark
2017-08-03 16:47 ` [U-Boot] [PATCH 3/3] video: add config option to skip framebuffer clear Rob Clark
2017-08-28 22:15 ` Anatolij Gustschin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170721190710.7758-4-robdclark@gmail.com \
--to=robdclark@gmail.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox