public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] video: Add an option to skip video initialization
@ 2009-05-15  6:38 Stefan Roese
  2009-05-15  8:07 ` [U-Boot] [PATCH 0/2] drv_video_init() cleanup / extension Wolfgang Denk
                   ` (3 more replies)
  0 siblings, 4 replies; 18+ messages in thread
From: Stefan Roese @ 2009-05-15  6:38 UTC (permalink / raw)
  To: u-boot

This patch adds an option to skip the video initialization on for all
video drivers. This is needed for the CPCI750 which can be built as CPCI
host and adapter/target board. And the adapter board can't access the
video cards located on the CompactPCI bus.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Anatolij Gustschin <agust@denx.de>
---
This patch replaces the previous one [video: ct6900: Add an option to skip
video initialization]. The test is now moved out of the ct6900 file into
the generic video init routine drv_video_init() as suggested by Anatolij.

Thanks,
Stefan

 drivers/video/cfb_console.c |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c
index 5ee2314..d3d5a6d 100644
--- a/drivers/video/cfb_console.c
+++ b/drivers/video/cfb_console.c
@@ -1330,11 +1330,27 @@ static int video_init (void)
 
 /*****************************************************************************/
 
+/*
+ * Implement a weak default function for boards that optionally
+ * need to skip the video initialization.
+ */
+int __board_video_skip(void)
+{
+	/* As default, don't skip test */
+	return 0;
+}
+int board_video_skip(void) __attribute__((weak, alias("__board_video_skip")));
+
+
 int drv_video_init (void)
 {
 	int skip_dev_init;
 	device_t console_dev;
 
+	/* Check if video initialization should be skipped */
+	if (board_video_skip())
+		return 0;
+
 	skip_dev_init = 0;
 
 	/* Init video chip - returns with framebuffer cleared */
-- 
1.6.2.5

^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2009-05-16  7:28 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-15  6:38 [U-Boot] [PATCH] video: Add an option to skip video initialization Stefan Roese
2009-05-15  8:07 ` [U-Boot] [PATCH 0/2] drv_video_init() cleanup / extension Wolfgang Denk
2009-05-15  8:07 ` [U-Boot] [PATCH 1/2] drv_video_init(): simplify logic Wolfgang Denk
2009-05-15 23:20   ` Anatolij Gustschin
2009-05-16  7:28     ` Wolfgang Denk
2009-05-15  8:07 ` [U-Boot] [PATCH 2/2] video: Add an option to skip video initialization Wolfgang Denk
2009-05-15  8:22   ` Jean-Christophe PLAGNIOL-VILLARD
2009-05-15 10:35     ` Anatolij Gustschin
2009-05-15 12:37       ` Jean-Christophe PLAGNIOL-VILLARD
2009-05-15 13:18         ` Anatolij Gustschin
2009-05-15 13:50           ` Wolfgang Denk
2009-05-15 13:56             ` Jean-Christophe PLAGNIOL-VILLARD
2009-05-15 15:20               ` Wolfgang Denk
2009-05-15 13:50         ` Wolfgang Denk
2009-05-15 10:41   ` Anatolij Gustschin
2009-05-15 10:48     ` Stefan Roese
2009-05-15 23:23   ` Anatolij Gustschin
2009-05-15 23:38 ` [U-Boot] [PATCH] " Anatolij Gustschin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox