mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Steffen Hemer <S.Hemer@phytec.de>,
	Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH 8/8] sandbox: add headless_defconfig
Date: Fri, 17 May 2024 15:26:56 +0200	[thread overview]
Message-ID: <20240517132656.3151273-9-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20240517132656.3151273-1-a.fatoum@pengutronix.de>

Build with no console whatsoever is not a common configuration for
development, but is used in some verified boot scenarios. Some
configurations go even further and disable the shell altogether.
Add headless.config and noshell.config fragments that describes these
configurations and sandbox targets that makes use of them.

This will be automatically found by CI and built to ensure that we
don't inadvertently break CONFIG_CONSOLE_NONE and CONFIG_SHELL_NONE
without noticing.

Platforms with CONFIG_CONSOLE_NONE are also likely to disable the
DEFAULT_ENVIRONMENT, so this is added to headless_defconfig as well.

More options can be added to the configs as needed to increase CI's
build coverage.

Cc: Steffen Hemer <S.Hemer@phytec.de>
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 arch/sandbox/Makefile                 | 8 ++++++++
 common/boards/configs/headless.config | 3 +++
 common/boards/configs/noshell.config  | 2 ++
 3 files changed, 13 insertions(+)
 create mode 100644 common/boards/configs/headless.config
 create mode 100644 common/boards/configs/noshell.config

diff --git a/arch/sandbox/Makefile b/arch/sandbox/Makefile
index c2906c0b1c0c..d5327d44e097 100644
--- a/arch/sandbox/Makefile
+++ b/arch/sandbox/Makefile
@@ -2,6 +2,14 @@
 
 KBUILD_DEFCONFIG := sandbox_defconfig
 
+generated_configs += headless_defconfig noshell_defconfig lockdown_defconfig
+headless_defconfig:
+	$(call merge_into_defconfig,sandbox_defconfig,headless)
+noshell_defconfig:
+	$(call merge_into_defconfig,sandbox_defconfig,noshell)
+lockdown_defconfig:
+	$(call merge_into_defconfig,sandbox_defconfig,headless noshell)
+
 KBUILD_CPPFLAGS += -D__SANDBOX__ -fno-strict-aliasing -fvisibility=hidden
 
 
diff --git a/common/boards/configs/headless.config b/common/boards/configs/headless.config
new file mode 100644
index 000000000000..f1eb1e6fa717
--- /dev/null
+++ b/common/boards/configs/headless.config
@@ -0,0 +1,3 @@
+CONFIG_CONSOLE_NONE=y
+# CONFIG_ENV_HANDLING is not set
+CONFIG_DEFAULT_ENVIRONMENT=y
diff --git a/common/boards/configs/noshell.config b/common/boards/configs/noshell.config
new file mode 100644
index 000000000000..4696a1b3f971
--- /dev/null
+++ b/common/boards/configs/noshell.config
@@ -0,0 +1,2 @@
+CONFIG_SHELL_NONE=y
+# CONFIG_DISABLE_INPUT is not set
-- 
2.39.2




  parent reply	other threads:[~2024-05-17 13:27 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-17 13:26 [PATCH 0/8] kconfig: cut down on duplication with merged defconfigs Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 1/8] test: move common config fragments into common/boards/configs Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 2/8] kconfig: merge_config.sh: sync with Linux v6.9 Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 3/8] kbuild: add support for merged defconfigs Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 4/8] MIPS: make use of " Ahmad Fatoum
2024-05-20 10:23   ` [PATCH] fixup! " Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 5/8] sandbox: stdio: fix ctrlc link error when CONFIG_CONSOLE_NONE=y Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 6/8] net: fix build with CONFIG_SHELL_NONE Ahmad Fatoum
2024-05-17 13:26 ` [PATCH 7/8] power: reset: reboot-mode: fix link error without globalvar Ahmad Fatoum
2024-05-17 13:26 ` Ahmad Fatoum [this message]
2024-05-21  6:20 ` [PATCH 0/8] kconfig: cut down on duplication with merged defconfigs Sascha Hauer

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=20240517132656.3151273-9-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=S.Hemer@phytec.de \
    --cc=barebox@lists.infradead.org \
    /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