mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH master 1/3] firmware: disable MISSING_FIRMWARE_ERROR for COMPILE_TEST builds
@ 2025-03-19 16:08 Ahmad Fatoum
  2025-03-19 16:08 ` [PATCH master 2/3] sandbox: do not enable SANDBOX_LINUX_I386 in allyesconfig Ahmad Fatoum
  2025-03-19 16:08 ` [PATCH master 3/3] Documentation: devicetree: fix Sphinx warnings Ahmad Fatoum
  0 siblings, 2 replies; 3+ messages in thread
From: Ahmad Fatoum @ 2025-03-19 16:08 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

An allyes build will enable all options possible and thus usually fail
to build, because it enables CONFIG_MISSING_FIRMWARE_ERROR along with
DRIVER_NET_FSL_FMAN, which requires firmware to function at runtime.

Fix this by disabling MISSING_FIRMWARE_ERROR if COMPILE_TEST is enabled.
This works, because Kconfig encounters COMPILE_TEST first.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 firmware/Kconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/firmware/Kconfig b/firmware/Kconfig
index ba005976c5a1..9253bc14cb0c 100644
--- a/firmware/Kconfig
+++ b/firmware/Kconfig
@@ -9,6 +9,8 @@ config EXTRA_FIRMWARE_DIR
 config MISSING_FIRMWARE_ERROR
 	bool "Fail the build when required firmware is missing"
 	default y
+	# This prevents firmware errors from breaking allyesconfig builds
+	depends on !COMPILE_TEST
 	help
 	  In-tree Defconfigs that enable multiple boards with different firmware
 	  binary requirements would say y here, so you don't need unrelated firmware
-- 
2.39.5




^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH master 2/3] sandbox: do not enable SANDBOX_LINUX_I386 in allyesconfig
  2025-03-19 16:08 [PATCH master 1/3] firmware: disable MISSING_FIRMWARE_ERROR for COMPILE_TEST builds Ahmad Fatoum
@ 2025-03-19 16:08 ` Ahmad Fatoum
  2025-03-19 16:08 ` [PATCH master 3/3] Documentation: devicetree: fix Sphinx warnings Ahmad Fatoum
  1 sibling, 0 replies; 3+ messages in thread
From: Ahmad Fatoum @ 2025-03-19 16:08 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

On sandbox, CONFIG_32BIT and CONFIG_64BIT are determined by the used
compiler. As special case, building sandbox on x86_64 allows
selecting a 32-bit build via CONFIG_SANDBOX_LINUX_I386 if the compiler
supports it.

This option is disabled by default, but allyesconfig turns it on,
alongside drivers requiring host libraries like FTDI and SDL, which
are usually not required.

To make allyesconfig work out-of-the-box, restructure the config
symbols and give 64BIT a prompt only if i386 support is possible.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 arch/sandbox/Kconfig | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/arch/sandbox/Kconfig b/arch/sandbox/Kconfig
index c1a51d4f021d..7c568f9ddb29 100644
--- a/arch/sandbox/Kconfig
+++ b/arch/sandbox/Kconfig
@@ -44,17 +44,23 @@ config CC_HAS_LINUX_I386_SUPPORT
 
 config 64BIT
 	bool
-	default n if SANDBOX_LINUX_I386
+	prompt "64-bit barebox" if CC_HAS_LINUX_I386_SUPPORT
 	default CC_IS_64BIT
 	select ARCH_DMA_ADDR_T_64BIT
 	select PHYS_ADDR_T_64BIT
 	select ARCH_HAS_ASAN_FIBER_API if ASAN
+	help
+	  Say n here if you want to build a 32-bit barebox, either
+	  to be more similar to a target platform or to reduce
+	  memory usage when fuzzing for example.
+
+	  If unsure, say y.
 
 config 32BIT
 	def_bool !64BIT
 
 config SANDBOX_LINUX_I386
-	bool "32-bit x86 barebox" if CC_HAS_LINUX_I386_SUPPORT
+	def_bool 32_BIT && CC_HAS_LINUX_I386_SUPPORT
 
 config SANDBOX_REEXEC
 	prompt "exec(2) reset handler"
-- 
2.39.5




^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH master 3/3] Documentation: devicetree: fix Sphinx warnings
  2025-03-19 16:08 [PATCH master 1/3] firmware: disable MISSING_FIRMWARE_ERROR for COMPILE_TEST builds Ahmad Fatoum
  2025-03-19 16:08 ` [PATCH master 2/3] sandbox: do not enable SANDBOX_LINUX_I386 in allyesconfig Ahmad Fatoum
@ 2025-03-19 16:08 ` Ahmad Fatoum
  1 sibling, 0 replies; 3+ messages in thread
From: Ahmad Fatoum @ 2025-03-19 16:08 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

Building the barebox documentation results in an number of warnings
predominantly in the autogenerated docs from command help text.

Outside of that, there is warnings only in the DT bindings:

  bindings/barebox/virtual-reg.rst:25:
  WARNING: Inline emphasis start-string without end-string.

  bindings/barebox/virtual-reg.rst:28:
  WARNING: Definition list ends without a blank line; unexpected unindent.

  bindings/barebox/virtual-reg.rst:29:
  WARNING: Block quote ends without a blank line; unexpected unindent.

  bindings/clocks/xlnx,ps7-clkc.rst:
  WARNING: document isn't included in any toctree

Fix the devicetree binding warnings.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 Documentation/devicetree/bindings/barebox/virtual-reg.rst | 2 +-
 Documentation/devicetree/index.rst                        | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/barebox/virtual-reg.rst b/Documentation/devicetree/bindings/barebox/virtual-reg.rst
index 7d576d0cef6f..a69d23144755 100644
--- a/Documentation/devicetree/bindings/barebox/virtual-reg.rst
+++ b/Documentation/devicetree/bindings/barebox/virtual-reg.rst
@@ -13,7 +13,7 @@ by subtracting ``virtual-reg`` from the first address in ``reg``.
 
 This is normally used to map I/O memory away from the zero page, so it
 can be used again to trap null pointer dereferences, while allowing
-full access to the device memory::
+full access to the device memory.
 
 .. code-block:: none
 
diff --git a/Documentation/devicetree/index.rst b/Documentation/devicetree/index.rst
index cd9270da1d21..2ca8b72be1ac 100644
--- a/Documentation/devicetree/index.rst
+++ b/Documentation/devicetree/index.rst
@@ -143,6 +143,7 @@ Contents:
    :maxdepth: 1
 
    bindings/barebox/*
+   bindings/clocks/*
    bindings/firmware/*
    bindings/leds/*
    bindings/misc/*
-- 
2.39.5




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-03-19 16:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-19 16:08 [PATCH master 1/3] firmware: disable MISSING_FIRMWARE_ERROR for COMPILE_TEST builds Ahmad Fatoum
2025-03-19 16:08 ` [PATCH master 2/3] sandbox: do not enable SANDBOX_LINUX_I386 in allyesconfig Ahmad Fatoum
2025-03-19 16:08 ` [PATCH master 3/3] Documentation: devicetree: fix Sphinx warnings Ahmad Fatoum

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox