From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D81EFC433EF for ; Mon, 28 Mar 2022 18:50:52 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 6929683938; Mon, 28 Mar 2022 20:50:50 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gateworks-com.20210112.gappssmtp.com header.i=@gateworks-com.20210112.gappssmtp.com header.b="tjiXre5I"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 96B7483938; Mon, 28 Mar 2022 20:50:48 +0200 (CEST) Received: from mail-pg1-x52b.google.com (mail-pg1-x52b.google.com [IPv6:2607:f8b0:4864:20::52b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 89C8B80F92 for ; Mon, 28 Mar 2022 20:50:40 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tharvey@gateworks.com Received: by mail-pg1-x52b.google.com with SMTP id c11so12885616pgu.11 for ; Mon, 28 Mar 2022 11:50:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gateworks-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=BeD5cUvjddE2uWgC3uVkdRIrR7zsaTV1WldIubrARTk=; b=tjiXre5I9i8m6mfifRwVTA9E+j3w4D6I4KRnXwipb8+7kc/oqFN+48IVvnHOPu5cL/ ywZaew0hpkoUhBMVnS0vZpAOi/UO4yJlcrGjXWh/NZkRIJsXB0BboxxQwjjikVRFVhzG wY21e+qcTS8QEeJT+Nn8RjC8idC6QJe7K2IgOpQEaK2HjbKw0D32+woUim+LA/qX/Opl 7sGGpL96eDHQaX/7IqI1AZcwAkCxFhIHRtBYRaWb+CkipYbV4hjBNlapLOYxEEhE59VB YtsesSHEmGOi8FDIhBw89Zr/R70aeXQ9Qh6gQo7pt0V76AQ6i7ewSxho9MvpILMtCE9F /fGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=BeD5cUvjddE2uWgC3uVkdRIrR7zsaTV1WldIubrARTk=; b=s/otbnvF1ENH5K2HPhU9qH0lN3uDv20oQnR0c6YvjfXyQkv+qugSTha4MWoDoNiMrl M1mXPLbn59vWpne1yNwc6hFHQhIb1XGkUjf5qBloSSHMEiRi6vv34Y+CUTw8mtIFgGRP IUyhQXd1BwwYiIPsV2ew+MgFDzImVMlh7SLpJaVvKWHeMl9s2NL6W2pAKcHmSLSJ5QgZ Hb8WL0YV9wSjYApxCxjdbvcp28ig8Numb4gRaKqBlEBNz3xGb0uwwNjMLq4dQ/Apmvfk rNrySVAKYRQVyczNb/6qZGHI/IsfBLtTgN6kl/l9Vyfj55JuIHoMScIOlfvBKLYUPbyF NDUg== X-Gm-Message-State: AOAM532OeoPxYHPeF6qIreBYfCCihZ5UzMYlNP+xKCJwhF/HpAZ//qnm apbXRg7NHOw0Ii8wbekcRwUS0c3Ht2jzm6oUT82M0Q== X-Google-Smtp-Source: ABdhPJwGLM+LA3AdX4ATnA440sNP+GNKlY2y6uhFZv2Af9CPPJeVsQCWQ1F4rlRGgCFK9ZTONjHgsv0GsTZpF7Kkyxc= X-Received: by 2002:a63:af02:0:b0:386:5aa9:a88c with SMTP id w2-20020a63af02000000b003865aa9a88cmr10939009pge.533.1648493438682; Mon, 28 Mar 2022 11:50:38 -0700 (PDT) MIME-Version: 1.0 References: <20211119202408.1815506-1-sjg@chromium.org> <20211119202408.1815506-20-sjg@chromium.org> In-Reply-To: From: Tim Harvey Date: Mon, 28 Mar 2022 11:50:27 -0700 Message-ID: Subject: Re: [PATCH 19/23] video: Support showing the U-Boot logo To: Simon Glass , festevam@gmail.com Cc: U-Boot Mailing List , Anatolij Gustschin , Tom Rini , Alistair Delva , Heinrich Schuchardt , =?UTF-8?B?TWFyZWsgQmVow7pu?= , Roger Pau Monne Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean On Sun, Mar 27, 2022 at 11:36 PM Simon Glass wrote: > > Hi Tim, > > On Tue, 15 Mar 2022 at 10:14, Tim Harvey wrote: > > > > On Fri, Nov 19, 2021 at 12:28 PM Simon Glass wrote: > > > > > > Show the U-Boot logo by default. This is only 7KB in size so seems li= ke > > > a useful default for boards that enable a display. > > > > > > If SPLASH_SCREEN is enabled, it is not enabled by default, so as not = to > > > conflict with that feature. > > > > > > Also disable it for tests, since we don't want to complicate the outp= ut. > > > > > > Signed-off-by: Simon Glass > > > --- > > > > > > drivers/video/Kconfig | 1 + > > > drivers/video/Makefile | 3 +++ > > > drivers/video/sandbox_sdl.c | 2 ++ > > > drivers/video/u_boot_logo.bmp | Bin 0 -> 6932 bytes > > > drivers/video/video-uclass.c | 26 ++++++++++++++++++++ > > > include/video.h | 2 ++ > > > scripts/Makefile.lib | 21 +++++++++++++++++ > > > test/dm/video.c | 43 +++++++++++++++++++++++++++-----= -- > > > 8 files changed, 89 insertions(+), 9 deletions(-) > > > create mode 100644 drivers/video/u_boot_logo.bmp > > > > > > diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig > > > index 7a73ecc1f40..e601b47806b 100644 > > > --- a/drivers/video/Kconfig > > > +++ b/drivers/video/Kconfig > > > @@ -17,6 +17,7 @@ config DM_VIDEO > > > config VIDEO_LOGO > > > bool "Show the U-Boot logo on the display" > > > depends on DM_VIDEO > > > + select VIDEO_BMP_RLE8 > > > help > > > This enables showing the U-Boot logo on the display when a = video > > > device is probed. It appears at the top right. The logo its= elf is at > > > diff --git a/drivers/video/Makefile b/drivers/video/Makefile > > > index 8956b5f9b00..4038395b128 100644 > > > --- a/drivers/video/Makefile > > > +++ b/drivers/video/Makefile > > > @@ -17,6 +17,9 @@ obj-$(CONFIG_DM_VIDEO) +=3D video_bmp.o > > > obj-$(CONFIG_PANEL) +=3D panel-uclass.o > > > obj-$(CONFIG_DM_PANEL_HX8238D) +=3D hx8238d.o > > > obj-$(CONFIG_SIMPLE_PANEL) +=3D simple_panel.o > > > + > > > +obj-$(CONFIG_VIDEO_LOGO) +=3D u_boot_logo.o > > > + > > > endif > > > > > > obj-${CONFIG_EXYNOS_FB} +=3D exynos/ > > > diff --git a/drivers/video/sandbox_sdl.c b/drivers/video/sandbox_sdl.= c > > > index 2afe66fab1a..9081c7da62e 100644 > > > --- a/drivers/video/sandbox_sdl.c > > > +++ b/drivers/video/sandbox_sdl.c > > > @@ -82,12 +82,14 @@ static void set_bpp(struct udevice *dev, enum vid= eo_log2_bpp l2bpp) > > > > > > int sandbox_sdl_set_bpp(struct udevice *dev, enum video_log2_bpp l2b= pp) > > > { > > > + struct video_uc_plat *uc_plat =3D dev_get_uclass_plat(dev); > > > int ret; > > > > > > if (device_active(dev)) > > > return -EINVAL; > > > sandbox_sdl_remove_display(); > > > > > > + uc_plat->hide_logo =3D true; > > > set_bpp(dev, l2bpp); > > > > > > ret =3D device_probe(dev); > > > diff --git a/drivers/video/u_boot_logo.bmp b/drivers/video/u_boot_log= o.bmp > > > new file mode 100644 > > > index 0000000000000000000000000000000000000000..47f1e9b99789584d2f6dd= 71e954b51927b35d783 > > > GIT binary patch > > > literal 6932 > > > zcmb7J3sjWXwf?sM%m9M}3aA(*B(X##snNz*U$IeRG>LimKpwtD@qvhnD4<9bH9<{c > > > zuq4JwK}|`-nLKJMq^L > > z`OZH3?7h!E$7#<54T15u)dZ|(>zL;!@P@FRI}mW$dVc?6U;U=3DdoSVeY|Ld>M|BzlY > > > zU9fTnu=3DepjSoH)D$KUFieXwSh32UFUVBJ&Rh=3D1COl}`m>&9h#JdwL+&%nnBEvw>L= m > > > zd|#}e>xWg(55mf4?nT1fepoYa2v*F!7i;GaMeMx$urA_mteig#@e4w+EMg?qN8W>k > > > zsCy9`^&r+pkHE^vM-U$qj%Cq5!TLoHAYsvi*sx?2Vi!)v#-$G-e(6{&T{IQzmyg5p > > > zrPHxt#ZQqKJ07viXJF~_S=3Dh8{A`(_Vh83}MusC);HmsS7#I@6~aosd5i(7zA@sDHq > > > z>L?_{&q89tlUTBLA(pIJj*SU(uxwo{HYd)*qWCx@ZQ|HXQCPZREjA`aW8sEP*qpo& > > > zNn00T>E>i4rz}BC(l%^LU5-UbJFz)!1(LSMB06~&w(MAm > > z`;e5e3DK#qV9N`ek-RGj3%9?DZJEi~oVg8))3Xts{w7lQZo`(nsff > > za#t?4Wu+tKrA(ym--)!WJ&4(J9Lf7%#DdI|*m~e4MD8iTwu4znd3isg_BoLH$^pc@ > > > z_#V<;J&5gxUPeULhuHesAw=3DyjLdxN6q-MW?B?nI<`oKqsICvImKYtV3bB > > z^6!!U##=3D}|l85<+E+XyCV~BX|61E>bj`c@A#18ujL>?|f`de=3D!D*JQHJN!pvymbn= x > > > zx$k2B&;J7vIajg$*hwsSy$U<>-bebe4>9M63p > > z9Q_j_-uwa!j$X(1{4&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*iaf)^CVOrm>`!AqVv^@3^pvpbW5s+&-y*je4c&6rL_@|0 > > > zlsQeAstKMO7yB`+T+WGU9OqHDFe{!k-it{6N~S;JxzSN>H#4UB*2gc6)bJ2 > > zD%l{pscM?WJiC3Jd6aPz?5pUJ%)I%`%#Z)rb6X@$lcSuyh86dI(H=3D1FoHiwEG2R6$ > > > zm}UKXsD6rSlMi{`m5@3(+;i)t9u~=3D9mZ&7v+C%kMmYE{zO|ON>N#Vw=3Dx*w^~EOV}= ? > > > z`s^&vog;GpNY9=3DBS=3DxNW@?%wJ?R$O_ZqWK;r}3^3fE~t5MIh3Q*N`Bj7_Te?u+{T= I > > > zBwDi38i*~z{|rJfHW@Eo!ARu#)VrE`4NNfJ?S^2T@jf^dYm8UO5X2cTnS4{#Vnw}* > > > z-h-Z3*4}s5`>>EG>Ls@Kbv6tOjMv)U*V_?zUes%DIA)7_-|c<# > > wA@94_V)cG3+BniCF!%phCa^V`EuNoDjq0U&Do6FaK0m2mbu}=3D?pJWRCZ}IWH!~g&Q > > > > > > literal 0 > > > HcmV?d00001 > > > > > > diff --git a/drivers/video/video-uclass.c b/drivers/video/video-uclas= s.c > > > index fafd05e373f..feed9c9a949 100644 > > > --- a/drivers/video/video-uclass.c > > > +++ b/drivers/video/video-uclass.c > > > @@ -305,6 +305,24 @@ int video_sync_copy_all(struct udevice *dev) > > > > > > #endif > > > > > > +#define SPLASH_DECL(_name) \ > > > + extern u8 __splash_ ## _name ## _begin[]; \ > > > + extern u8 __splash_ ## _name ## _end[] > > > + > > > +#define SPLASH_START(_name) __splash_ ## _name ## _begin > > > + > > > +SPLASH_DECL(u_boot_logo); > > > + > > > +static int show_splash(struct udevice *dev) > > > +{ > > > + u8 *data =3D SPLASH_START(u_boot_logo); > > > + int ret; > > > + > > > + ret =3D video_bmp_display(dev, map_to_sysmem(data), -4, 4, tr= ue); > > > + > > > + return 0; > > > +} > > > + > > > /* Set up the display ready for use */ > > > static int video_post_probe(struct udevice *dev) > > > { > > > @@ -370,6 +388,14 @@ static int video_post_probe(struct udevice *dev) > > > return ret; > > > } > > > > > > + if (IS_ENABLED(CONFIG_VIDEO_LOGO) && !plat->hide_logo) { > > > + ret =3D show_splash(dev); > > > + if (ret) { > > > + log_debug("Cannot show splash screen\n"); > > > + return ret; > > > + } > > > + } > > > + > > > return 0; > > > }; > > > > > > diff --git a/include/video.h b/include/video.h > > > index 6948cdf5796..59c9d9c18ca 100644 > > > --- a/include/video.h > > > +++ b/include/video.h > > > @@ -30,12 +30,14 @@ struct udevice; > > > * @base: Base address of frame buffer, 0 if not yet known > > > * @copy_base: Base address of a hardware copy of the frame buffer. = See > > > * CONFIG_VIDEO_COPY. > > > + * @hide_logo: Hide the logo (used for testing) > > > */ > > > struct video_uc_plat { > > > uint align; > > > uint size; > > > ulong base; > > > ulong copy_base; > > > + bool hide_logo; > > > }; > > > > > > enum video_polarity { > > > diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib > > > index 39f03398ed8..06cc2d938db 100644 > > > --- a/scripts/Makefile.lib > > > +++ b/scripts/Makefile.lib > > > @@ -372,6 +372,27 @@ cmd_S_ttf=3D = \ > > > $(obj)/%.S: $(src)/%.ttf > > > $(call cmd,S_ttf) > > > > > > +# Splash logos > > > +# ------------------------------------------------------------------= --------- > > > + > > > +# Generate an assembly file to wrap the splash data > > > +quiet_cmd_S_splash=3D TTF $@ > > > +# Modified for U-Boot > > > +cmd_S_splash=3D \ > > > +( \ > > > + echo '.section .rodata.splash.init,"a"'; \ > > > + echo '.balign 16'; \ > > > + echo '.global __splash_$(*F)_begin'; \ > > > + echo '__splash_$(*F)_begin:'; \ > > > + echo '.incbin "$<" '; \ > > > + echo '__splash_$(*F)_end:'; \ > > > + echo '.global __splash_$(*F)_end'; \ > > > + echo '.balign 16'; \ > > > +) > $@ > > > + > > > +$(obj)/%.S: $(src)/%.bmp > > > + $(call cmd,S_splash) > > > + > > > # EFI applications > > > # A Makefile target *.efi is built as EFI application. > > > # A Makefile target *_efi.S wraps *.efi as built-in EFI application. > > > diff --git a/test/dm/video.c b/test/dm/video.c > > > index 4e76574a913..d4a3c9c6c17 100644 > > > --- a/test/dm/video.c > > > +++ b/test/dm/video.c > > > @@ -115,6 +115,31 @@ static int select_vidconsole(struct unit_test_st= ate *uts, const char *drv_name) > > > return 0; > > > } > > > > > > +/** > > > + * video_get_nologo() - Disable the logo on the video device and ret= urn it > > > + * > > > + * @uts: Test state > > > + * @devp: Returns video device > > > + * @return 0 if OK, -ve on error > > > + */ > > > +static int video_get_nologo(struct unit_test_state *uts, struct udev= ice **devp) > > > +{ > > > + struct video_uc_plat *uc_plat; > > > + struct udevice *dev; > > > + > > > + ut_assertok(uclass_find_first_device(UCLASS_VIDEO, &dev)); > > > + ut_assertnonnull(dev); > > > + uc_plat =3D dev_get_uclass_plat(dev); > > > + uc_plat->hide_logo =3D true; > > > + > > > + /* now probe it */ > > > + ut_assertok(uclass_first_device_err(UCLASS_VIDEO, &dev)); > > > + ut_assertnonnull(dev); > > > + *devp =3D dev; > > > + > > > + return 0; > > > +} > > > + > > > /* Test text output works on the video console */ > > > static int dm_test_video_text(struct unit_test_state *uts) > > > { > > > @@ -125,7 +150,7 @@ static int dm_test_video_text(struct unit_test_st= ate *uts) > > > #define SCROLL_LINES 100 > > > > > > ut_assertok(select_vidconsole(uts, "vidconsole0")); > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_asserteq(46, compress_frame_buffer(uts, dev)); > > > > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > @@ -157,7 +182,7 @@ static int dm_test_video_chars(struct unit_test_s= tate *uts) > > > const char *test_string =3D "Well\b\b\b\bxhe is\r \n\ta very = \amodest \bman\n\t\tand Has much to\b\bto be modest about."; > > > > > > ut_assertok(select_vidconsole(uts, "vidconsole0")); > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > vidconsole_put_string(con, test_string); > > > ut_asserteq(466, compress_frame_buffer(uts, dev)); > > > @@ -174,7 +199,7 @@ static int dm_test_video_ansi(struct unit_test_st= ate *uts) > > > struct udevice *dev, *con; > > > > > > ut_assertok(select_vidconsole(uts, "vidconsole0")); > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > > > > /* reference clear: */ > > > @@ -222,7 +247,7 @@ static int check_vidconsole_output(struct unit_te= st_state *uts, int rot, > > > plat =3D dev_get_plat(dev); > > > plat->rot =3D rot; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > ut_asserteq(46, compress_frame_buffer(uts, dev)); > > > > > > @@ -311,7 +336,7 @@ static int dm_test_video_bmp(struct unit_test_sta= te *uts) > > > struct udevice *dev; > > > ulong addr; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(read_file(uts, "tools/logos/denx.bmp", &addr)); > > > > > > ut_assertok(video_bmp_display(dev, addr, 0, 0, false)); > > > @@ -433,7 +458,7 @@ static int dm_test_video_bmp_comp(struct unit_tes= t_state *uts) > > > struct udevice *dev; > > > ulong addr; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(read_file(uts, "tools/logos/denx-comp.bmp", &addr= )); > > > > > > ut_assertok(video_bmp_display(dev, addr, 0, 0, false)); > > > @@ -487,7 +512,7 @@ static int dm_test_video_truetype(struct unit_tes= t_state *uts) > > > struct udevice *dev, *con; > > > const char *test_string =3D "Criticism may not be agreeable, = but it is necessary. It fulfils the same function as pain in the human body= . It calls attention to an unhealthy state of things. Some see private ente= rprise as a predatory target to be shot, others as a cow to be milked, but = few are those who see it as a sturdy horse pulling the wagon. The \aprice O= F\b\bof greatness\n\tis responsibility.\n\nBye"; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > vidconsole_put_string(con, test_string); > > > ut_asserteq(12237, compress_frame_buffer(uts, dev)); > > > @@ -508,7 +533,7 @@ static int dm_test_video_truetype_scroll(struct u= nit_test_state *uts) > > > plat =3D dev_get_plat(dev); > > > plat->font_size =3D 100; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > vidconsole_put_string(con, test_string); > > > ut_asserteq(35030, compress_frame_buffer(uts, dev)); > > > @@ -529,7 +554,7 @@ static int dm_test_video_truetype_bs(struct unit_= test_state *uts) > > > plat =3D dev_get_plat(dev); > > > plat->font_size =3D 100; > > > > > > - ut_assertok(uclass_get_device(UCLASS_VIDEO, 0, &dev)); > > > + ut_assertok(video_get_nologo(uts, &dev)); > > > ut_assertok(uclass_get_device(UCLASS_VIDEO_CONSOLE, 0, &con))= ; > > > vidconsole_put_string(con, test_string); > > > ut_asserteq(29018, compress_frame_buffer(uts, dev)); > > > -- > > > 2.34.0.rc2.393.gf8c9666880-goog > > > > > > > Simon, > > > > I find that this patch enables the default U-Boot Logo in the > > top-right corner for gwventana_*_defconfig even though I have a custom > > splash-screen (so I see both). > > > > I have the following in my defconfig: > > $ grep -e "SPLASH\|LOGO" configs/gwventana_nand_defconfig > > CONFIG_VIDEO_LOGO=3Dy > > CONFIG_SPLASH_SCREEN=3Dy > > CONFIG_SPLASH_SCREEN_ALIGN=3Dy > > > > If I disable VIDEO_LOGO I don't see either the U-Boot logo or my > > SPLASH_SCREEN. The commit log says "If SPLASH_SCREEN is enabled, it is > > not enabled by default, so as not to conflict with that feature." but > > I don't see where you do anything in this patch with SPLASH_SCREEN. > > I just mean in the Kconfig: > > config VIDEO_LOGO > bool "Show the U-Boot logo on the display" > depends on DM_VIDEO > default y if !SPLASH_SCREEN > ^^^^^ > > So if you enable both of them, you will get both, but by default > VIDEO_LOGO should be enabled only if SPLASH_SCREEN is not enabled. > > The splash code needs a rework too, I think. I just didn't get that far. > > Regards, > Simon Simon, Ok, sorry, I missed the 'default y if !SPLASH_SCREEN' as that was from a different patch. Currently if I disable VIDEO_LOGO and leave only SPASH_SCREEN enabled I get no display. Similarly if I enable VIDEO_LOGO and not SPLASH_SCREEN I get no display. If I go back to prior to this series (3a8b919932fd) splash works just fine so I'm trying to understand why now I loose video completely if I disable VIDEO_LOGO (which I wish wasn't enabled by default anyway when using my existing gwventana defconfigs). Fabio, do you have any imx6 boards that have defconfigs that enable SPLASH_SCREEN you can see if the same behavior occurs on? The behavior is that VIDEO_LOGO got enabled by default so you see the custom splash along with the U-Boot logo and if you disable VIDEO_LOGO you also loose the custom splash. Best Regards, Tim