From ae63057446b8bb45c37a6ea4e5db162ba4f25c78 Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Sat, 3 Nov 2012 11:41:40 +0000 Subject: [PATCH] video: Check for valid FB pointer before clearing This command will start erasing at memory address zero if there is not a valid framebuffer address that was found during video_init(). This is a common case with Chrome OS devices in normal mode when we do not execute the video option rom in coreboot. Signed-off-by: Duncan Laurie Signed-off-by: Simon Glass --- drivers/video/cfb_console.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index 9388859da7..26f673a96a 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -2293,6 +2293,8 @@ int video_get_screen_columns(void) void video_clear(void) { + if (!video_fb_address) + return; #ifdef VIDEO_HW_RECTFILL video_hw_rectfill(VIDEO_PIXEL_SIZE, /* bytes per pixel */ 0, /* dest pos x */ -- 2.25.1