diff --git a/commands/Kconfig b/commands/Kconfig index 6f9ccb82c..1d080e302 100644 --- a/commands/Kconfig +++ b/commands/Kconfig @@ -420,6 +420,7 @@ config CMD_REGINFO config CMD_VERSION tristate default y + depends on BANNER prompt "version" config CMD_HELP diff --git a/common/Kconfig b/common/Kconfig index ca4f09922..d184d9ed3 100644 --- a/common/Kconfig +++ b/common/Kconfig @@ -74,6 +74,10 @@ config LOCALVERSION_AUTO config BOARDINFO string +config BANNER + bool "display banner" + default y + config ENVIRONMENT_VARIABLES bool "environment variables support" diff --git a/common/Makefile b/common/Makefile index d1132c3e5..eaf74a616 100644 --- a/common/Makefile +++ b/common/Makefile @@ -17,7 +17,7 @@ obj-$(CONFIG_MALLOC_TLSF) += tlsf_malloc.o obj-$(CONFIG_MALLOC_TLSF) += tlsf.o obj-$(CONFIG_MALLOC_DUMMY) += dummy_malloc.o obj-y += clock.o -obj-y += version.o +obj-$(CONFIG_BANNER) += version.o obj-$(CONFIG_COMMAND_SUPPORT) += command.o obj-$(CONFIG_CONSOLE_FULL) += console.o obj-$(CONFIG_CONSOLE_SIMPLE) += console_simple.o diff --git a/include/common.h b/include/common.h index 2f37dd845..a89b3bdcd 100644 --- a/include/common.h +++ b/include/common.h @@ -198,7 +198,11 @@ int run_shell(void); int memory_display(char *addr, ulong offs, ulong nbytes, int size); extern const char version_string[]; +#ifdef CONFIG_BANNER void barebox_banner(void); +#else +static inline void barebox_banner(void) {} +#endif #define IOMEM(addr) ((void __force __iomem *)(addr))