From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH 2/2] common: bootm: reuse cdev_get_linux_rootarg()
Date: Mon, 15 Aug 2022 13:48:35 +0200 [thread overview]
Message-ID: <20220815114835.2277946-2-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20220815114835.2277946-1-a.fatoum@pengutronix.de>
CONFIG_MMCBLKDEV_ROOTARG=y so far had no effect on the root= option
generated by $global.bootm.root_dev. Have the bootm code reuse
cdev_get_linux_rootarg(), so it behaves the same as with boot from
file system.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
common/bootm.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/common/bootm.c b/common/bootm.c
index c0f7bca6ce86..2f02c156e56f 100644
--- a/common/bootm.c
+++ b/common/bootm.c
@@ -710,9 +710,8 @@ int bootm_boot(struct bootm_data *bootm_data)
const char *root_dev_name = devpath_to_name(bootm_data->root_dev);
const struct cdev *root_cdev = cdev_by_name(root_dev_name);
- if (root_cdev && root_cdev->uuid[0] != 0) {
- rootarg = basprintf("root=PARTUUID=%s", root_cdev->uuid);
- } else {
+ rootarg = cdev_get_linux_rootarg(root_cdev);
+ if (!rootarg) {
rootarg = ERR_PTR(-EINVAL);
if (!root_cdev)
--
2.30.2
next prev parent reply other threads:[~2022-08-15 11:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-15 11:48 [PATCH 1/2] fs: export cdev_get_linux_rootarg() for reuse Ahmad Fatoum
2022-08-15 11:48 ` Ahmad Fatoum [this message]
2022-08-16 8:26 ` 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=20220815114835.2277946-2-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.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