From: Vincent Mailhol <mailhol@kernel.org>
To: Helge Deller <deller@gmx.de>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Yoshinori Sato <ysato@users.sourceforge.jp>,
Rich Felker <dalias@libc.org>,
John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Cc: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org, linux-sh@vger.kernel.org,
Vincent Mailhol <mailhol@kernel.org>
Subject: [PATCH v2 3/6] video/logo: allow custom logo
Date: Thu, 01 Jan 2026 16:25:17 +0100 [thread overview]
Message-ID: <20260101-custom-logo-v2-3-8eec06dfbf85@kernel.org> (raw)
In-Reply-To: <20260101-custom-logo-v2-0-8eec06dfbf85@kernel.org>
Some people like to replace the default Tux boot logo by an image of
their own. There exist a few tutorials here [1] and there [2]. But
this requires modifying the sources which is a bit cumbersome.
Add a string entry in Kbuild for each of the logo categories
(monochrome, 16-colors, 224-colors). The string entry takes a path to
a .pbm or .ppm image allowing the user to more easily provide a custom
logo without having to modify the sources.
Add an help entry with a short hint on how to convert images to the
portable pixmap file format.
Update the Makefile accordingly. When converted to .c file, the logo
will have one of these fixed file name:
- logo_linux_mono.c
- logo_linux_vga16.c
- logo_linux_clut224.c:
depending on the image type and this regardless of the name of the
.pgm/.ppm source filename. This will allow for further simplifications
in an upcoming change.
[1] ArmadeuS Project wiki -- Linux Boot Logo
Link: https://www.armadeus.org/wiki/index.php?title=Linux_Boot_Logo
[2] Timesys -- How To Use a Custom Boot Logo / Splash Screen
Link: https://linuxlink.timesys.com/docs/wiki/engineering/HOWTO_Use_a_custom_boot_logo
Signed-off-by: Vincent Mailhol <mailhol@kernel.org>
---
drivers/video/logo/Kconfig | 41 +++++++++++++++++++++++++++++++++++++++++
drivers/video/logo/Makefile | 11 ++++++++++-
2 files changed, 51 insertions(+), 1 deletion(-)
diff --git a/drivers/video/logo/Kconfig b/drivers/video/logo/Kconfig
index ce6bb753522d..1d1651c067a1 100644
--- a/drivers/video/logo/Kconfig
+++ b/drivers/video/logo/Kconfig
@@ -22,14 +22,55 @@ config LOGO_LINUX_MONO
bool "Standard black and white Linux logo"
default y
+config LOGO_LINUX_MONO_FILE
+ string "Monochrome logo .pbm file"
+ depends on LOGO_LINUX_MONO
+ default "drivers/video/logo/logo_linux_mono.pbm"
+ help
+ Takes a path to a monochromatic logo in the portable pixmap file
+ format (.pbm). This defaults to the Tux penguin.
+
+ For example, the below ImageMagick command can be used to reduce
+ an image to black and white and convert it into a pbm file:
+
+ magick source_image -compress none destination.pbm
+
config LOGO_LINUX_VGA16
bool "Standard 16-color Linux logo"
default y
+config LOGO_LINUX_VGA16_FILE
+ string "16-color logo .ppm file"
+ depends on LOGO_LINUX_VGA16
+ default "drivers/video/logo/logo_linux_vga16.ppm"
+ help
+ Takes a path to a logo in the portable pixmap file format (.ppm),
+ using the 16 colors from the drivers/video/logo/clut_vga16.ppm
+ palette. This defaults to the Tux penguin.
+
+ For example, the below ImageMagick command can be used to reduce an
+ image to the VGA 16 colors palette and convert into a ppm file:
+
+ magick source_image -compress none \
+ -remap drivers/video/logo/clut_vga16.ppm destination.ppm
+
config LOGO_LINUX_CLUT224
bool "Standard 224-color Linux logo"
default y
+config LOGO_LINUX_CLUT224_FILE
+ string "224-color logo .ppm file"
+ depends on LOGO_LINUX_CLUT224
+ default "drivers/video/logo/logo_linux_clut224.ppm"
+ help
+ Takes a path to a 224-color logo in the portable pixmap file
+ format (.ppm). This defaults to the Tux penguin.
+
+ For example, the below ImageMagick command can be used to reduce
+ an image palette to 224 colors and convert it into a ppm file:
+
+ magick source_image -compress none -colors 224 destination.ppm
+
config LOGO_DEC_CLUT224
bool "224-color Digital Equipment Corporation Linux logo"
depends on MACH_DECSTATION || ALPHA
diff --git a/drivers/video/logo/Makefile b/drivers/video/logo/Makefile
index 3f249e9dcf37..ac8e9da3f51a 100644
--- a/drivers/video/logo/Makefile
+++ b/drivers/video/logo/Makefile
@@ -22,7 +22,16 @@ hostprogs := pnmtologo
# Create commands like "pnmtologo -t mono -n logo_mac_mono -o ..."
quiet_cmd_logo = LOGO $@
- cmd_logo = $(obj)/pnmtologo -t $2 -n $* -o $@ $<
+ cmd_logo = $(obj)/pnmtologo -t $2 -n $(basename $(notdir $@)) -o $@ $<
+
+$(obj)/logo_linux_mono.c: $(CONFIG_LOGO_LINUX_MONO_FILE) $(obj)/pnmtologo FORCE
+ $(call if_changed,logo,mono)
+
+$(obj)/logo_linux_vga16.c: $(CONFIG_LOGO_LINUX_VGA16_FILE) $(obj)/pnmtologo FORCE
+ $(call if_changed,logo,vga16)
+
+$(obj)/logo_linux_clut224.c: $(CONFIG_LOGO_LINUX_CLUT224_FILE) $(obj)/pnmtologo FORCE
+ $(call if_changed,logo,clut224)
$(obj)/%.c: $(src)/%.pbm $(obj)/pnmtologo FORCE
$(call if_changed,logo,mono)
--
2.52.0
next prev parent reply other threads:[~2026-01-01 15:25 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-01 15:25 [PATCH v2 0/6] video/logo: allow custom boot logo and simplify logic Vincent Mailhol
2026-01-01 15:25 ` [PATCH v2 1/6] video/logo: remove orphan .pgm Makefile rule Vincent Mailhol
2026-01-01 15:25 ` [PATCH v2 2/6] video/logo: add a type parameter to the logo makefile function Vincent Mailhol
2026-01-01 15:25 ` Vincent Mailhol [this message]
2026-01-01 15:25 ` [PATCH v2 4/6] newport_con: depend on LOGO_LINUX_CLUT224 instead of LOGO_SGI_CLUT224 Vincent Mailhol
2026-01-01 15:25 ` [PATCH v2 5/6] sh: defconfig: remove CONFIG_LOGO_SUPERH_* Vincent Mailhol
2026-01-01 15:25 ` [PATCH v2 6/6] video/logo: move logo selection logic to Kconfig Vincent Mailhol
2026-01-06 11:48 ` Geert Uytterhoeven
2026-01-06 12:56 ` Daniel Palmer
2026-01-06 20:10 ` Vincent Mailhol
2026-01-06 22:16 ` Finn Thain
2026-01-07 10:36 ` Geert Uytterhoeven
2026-01-07 12:20 ` Helge Deller
2026-01-07 13:53 ` Geert Uytterhoeven
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260101-custom-logo-v2-3-8eec06dfbf85@kernel.org \
--to=mailhol@kernel.org \
--cc=dalias@libc.org \
--cc=deller@gmx.de \
--cc=dri-devel@lists.freedesktop.org \
--cc=glaubitz@physik.fu-berlin.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sh@vger.kernel.org \
--cc=ysato@users.sourceforge.jp \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).