mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Johannes Zink <j.zink@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Johannes Zink <j.zink@pengutronix.de>,
	afa@pengutronix.de, jzi@pengutronix.de
Subject: [PATCH v2] Documentation: devicetree: list automatic boot argument fixups
Date: Fri, 17 Mar 2023 13:19:37 +0100	[thread overview]
Message-ID: <20230317121937.958131-1-j.zink@pengutronix.de> (raw)

Barebox automatically fixes up several properties to the root and
chosen node of the device tree passed to the booted system.

These entries contain information about the hardware, reset source
and the barebox version string.

Add documentation on how to query these information from the booted
linux system.

Signed-off-by: Johannes Zink <j.zink@pengutronix.de>
---
 Changelog:

 v1 -> v2: Correct errors in content spotted by Ahmad. While at it, fix some typos.

 Documentation/devicetree/index.rst | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

diff --git a/Documentation/devicetree/index.rst b/Documentation/devicetree/index.rst
index 36fa69058d1d..f85ce6608d14 100644
--- a/Documentation/devicetree/index.rst
+++ b/Documentation/devicetree/index.rst
@@ -151,3 +151,25 @@ Contents:
    bindings/regulator/*
    bindings/rtc/*
    bindings/watchdog/*
+
+Automatic Boot Argument Fixups to the Devicetree
+------------------------------------------------
+
+barebox automatically fixes up some boot and system information in the device tree.
+
+In the device tree root, barebox fixes up
+
+ * serial-number (if available)
+ * machine compatible (if overridden)
+
+In the ``chosen``-node, barebox fixes up
+
+ * barebox-version
+ * reset-source
+ * reset-source-instance (if available)
+ * reset-source-device (node-path, only if available)
+ * bootsource
+ * boot-hartid (only on RISC-V)
+
+These values can be read from the booted linux system in ``/proc/device-tree/``
+or ``/sys/firmware/devicetree/base``.
-- 
2.30.2




             reply	other threads:[~2023-03-17 12:21 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-17 12:19 Johannes Zink [this message]
2023-03-17 12:41 ` Ahmad Fatoum
2023-03-21  8:10 ` 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=20230317121937.958131-1-j.zink@pengutronix.de \
    --to=j.zink@pengutronix.de \
    --cc=afa@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=jzi@pengutronix.de \
    /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