[PATCH v2 0/3] commands: devlookup: add option to print kernel root option
Ahmad Fatoum
a.fatoum at pengutronix.de
Fri Apr 4 11:23:42 PDT 2025
There exists currently no way to view the kernel root option that
barebox would generate when instructed to via global.bootm.root_dev,
but without actually mounting the file system.
Add a new devlookup -k option that can print this. This can be useful in
scripts that want to fixup the root line, so it's interpreted by the rdinit,
but not by the kernel.
This applies on top of
https://lore.barebox.org/barebox/20250401104806.3959859-1-a.fatoum@pengutronix.de/T/#t
v1 -> v2:
- add new option to devlookup instead of findmnt as it's not really
about mounting
Ahmad Fatoum (3):
commands: devlookup: factor out cmd_export_val
commands: findmnt: add support for exporting target as variable
commands: devlookup: add option to print kernel root option
commands/Kconfig | 3 ++-
commands/devlookup.c | 50 +++++++++++++++++++++++++-------------------
commands/findmnt.c | 31 ++++++++++++++++++++-------
common/command.c | 13 ++++++++++++
include/command.h | 2 ++
5 files changed, 69 insertions(+), 30 deletions(-)
--
2.39.5
More information about the barebox
mailing list