From 57d29ebd74f43a195d4b71b621ae856dc69cae85 Mon Sep 17 00:00:00 2001 From: Subrata Banik Date: Sat, 14 Jun 2025 23:23:46 +0530 Subject: [PATCH] vc/google/chromeos: Don't pack `cb_plus_logo.bmp` if footer is present When a ChromeOS device has `SPLASH_SCREEN_FOOTER` Kconfig enabled and provides a logo path for an OEM-defined boot splash logo in the footer, it indicates that the device doesn't need to render `cb_plus_logo.bmp` logo (hence, avoid packing this bitmap for platforms that select `SPLASH_SCREEN_FOOTER` Kconfig). In such cases, only the main OEM logo should be displayed at the center of the splash screen along with custom bitmap at footer of the splash screen. BUG=b:423591644 TEST=Able to show OEM splash screen on google/fatcat. Change-Id: Ie5085babe2f8373058ce1aa18b7071260f2aef7f Signed-off-by: Subrata Banik Reviewed-on: https://review.coreboot.org/c/coreboot/+/88099 Reviewed-by: Kapil Porwal Tested-by: build bot (Jenkins) --- src/vendorcode/google/chromeos/Makefile.mk | 2 ++ src/vendorcode/google/chromeos/splash.c | 16 +++++++++++----- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/vendorcode/google/chromeos/Makefile.mk b/src/vendorcode/google/chromeos/Makefile.mk index 54673bcaf9..cfb4af45de 100644 --- a/src/vendorcode/google/chromeos/Makefile.mk +++ b/src/vendorcode/google/chromeos/Makefile.mk @@ -43,5 +43,7 @@ endef $(eval $(call add_bmp_logo_file_to_cbfs,CONFIG_CHROMEOS_FW_SPLASH_SCREEN, \ cb_logo.bmp,CONFIG_CHROMEOS_LOGO_PATH)) +ifneq ($(CONFIG_SPLASH_SCREEN_FOOTER),y) $(eval $(call add_bmp_logo_file_to_cbfs,CONFIG_CHROMEOS_FW_SPLASH_SCREEN, \ cb_plus_logo.bmp,CONFIG_CHROMEBOOK_PLUS_LOGO_PATH)) +endif diff --git a/src/vendorcode/google/chromeos/splash.c b/src/vendorcode/google/chromeos/splash.c index f63f52615c..5923513473 100644 --- a/src/vendorcode/google/chromeos/splash.c +++ b/src/vendorcode/google/chromeos/splash.c @@ -5,10 +5,16 @@ const char *bmp_logo_filename(void) { - if (chromeos_device_branded_plus_hard()) - return "cb_plus_logo.bmp"; - else if (chromeos_device_branded_plus_soft()) - return "cb_plus_logo.bmp"; - else + /* + * If the device has a custom boot splash footer logo (SPLASH_SCREEN_FOOTER Kconfig + * is enabled and a logo path is provided), we only return the main OEM logo, which + * will be displayed in the center of the splash screen. + */ + if (CONFIG(SPLASH_SCREEN_FOOTER)) return "cb_logo.bmp"; + + if (chromeos_device_branded_plus_hard() || chromeos_device_branded_plus_soft()) + return "cb_plus_logo.bmp"; + + return "cb_logo.bmp"; }