Merge branch 'master' of git://git.denx.de/u-boot-video
authorTom Rini <trini@konsulko.com>
Wed, 27 Jul 2016 19:22:21 +0000 (15:22 -0400)
committerTom Rini <trini@konsulko.com>
Wed, 27 Jul 2016 19:22:21 +0000 (15:22 -0400)
README
common/splash.c
common/splash_source.c
drivers/video/cfb_console.c
include/splash.h

diff --git a/README b/README
index ecbd07fcaefc299757bab41f959d3ad3a3947490..cadb571166bf4117730f81fd044d0beb21b8f1b3 100644 (file)
--- a/README
+++ b/README
@@ -840,6 +840,9 @@ The following options need to be configured:
                        CONFIG_CONSOLE_EXTRA_INFO
                                                additional board info beside
                                                the logo
+                       CONFIG_HIDE_LOGO_VERSION
+                                               do not display bootloader
+                                               version string
 
                When CONFIG_CFB_CONSOLE_ANSI is defined, console will support
                a limited number of ANSI escape sequences (cursor control,
index 561d35b4e41f9072d84e430d028e92ec8aecd8c3..89af437f2cafec3c648b13dc273e1fe4c1e4d287 100644 (file)
 #include <splash.h>
 #include <lcd.h>
 
+static struct splash_location default_splash_locations[] = {
+       {
+               .name = "sf",
+               .storage = SPLASH_STORAGE_SF,
+               .flags = SPLASH_STORAGE_RAW,
+               .offset = 0x0,
+       },
+       {
+               .name = "mmc_fs",
+               .storage = SPLASH_STORAGE_MMC,
+               .flags = SPLASH_STORAGE_FS,
+               .devpart = "0:1",
+       },
+       {
+               .name = "usb_fs",
+               .storage = SPLASH_STORAGE_USB,
+               .flags = SPLASH_STORAGE_FS,
+               .devpart = "0:1",
+       },
+       {
+               .name = "sata_fs",
+               .storage = SPLASH_STORAGE_SATA,
+               .flags = SPLASH_STORAGE_FS,
+               .devpart = "0:1",
+       },
+};
+
 __weak int splash_screen_prepare(void)
 {
-       return 0;
+       return splash_source_load(default_splash_locations,
+                                 ARRAY_SIZE(default_splash_locations));
 }
 
 #ifdef CONFIG_SPLASH_SCREEN_ALIGN
index 914f12f4cb554ca0cb4bade313232c4c625a6099..230b2db4d5b654f01568b3b01ac18f8317328153 100644 (file)
@@ -146,7 +146,11 @@ static int splash_init_usb(void)
        if (err)
                return err;
 
-       return usb_stor_scan(1) < 0 ? -ENODEV : 0;
+#ifndef CONFIG_DM_USB
+       err = usb_stor_scan(1) < 0 ? -ENODEV : 0;
+#endif
+
+       return err;
 }
 #else
 static inline int splash_init_usb(void)
index ef4984becb48283e5b9aee5e42220dda583b92b1..30b53dbb80ec1a7ebf966e293f6762791ea4c266 100644 (file)
@@ -1929,10 +1929,10 @@ static void plot_logo_or_black(void *screen, int x, int y, int black)
 static void *video_logo(void)
 {
        char info[128];
-       int space, len;
        __maybe_unused int y_off = 0;
        __maybe_unused ulong addr;
        __maybe_unused char *s;
+       __maybe_unused int len, space;
 
        splash_get_pos(&video_logo_xpos, &video_logo_ypos);
 
@@ -1978,6 +1978,7 @@ static void *video_logo(void)
 
        sprintf(info, " %s", version_string);
 
+#ifndef CONFIG_HIDE_LOGO_VERSION
        space = (VIDEO_LINE_LEN / 2 - VIDEO_INFO_X) / VIDEO_FONT_WIDTH;
        len = strlen(info);
 
@@ -2026,6 +2027,7 @@ static void *video_logo(void)
                        }
                }
        }
+#endif
 #endif
 
        return (video_fb_address + video_logo_height * VIDEO_LINE_LEN);
index 25df1cf5ad80395a1074c0c192dcf4b72f9db877..136eac7402465e34488687ccaa9d6d1bbb1b75b6 100644 (file)
@@ -47,7 +47,16 @@ struct splash_location {
        char *ubivol;   /* UBI volume-name for ubifsmount */
 };
 
+#ifdef CONFIG_SPLASH_SOURCE
 int splash_source_load(struct splash_location *locations, uint size);
+#else
+static inline int splash_source_load(struct splash_location *locations,
+                                    uint size)
+{
+       return 0;
+}
+#endif
+
 int splash_screen_prepare(void);
 
 #ifdef CONFIG_SPLASH_SCREEN_ALIGN