[PATCH 2/2] common: bootm: reuse cdev_get_linux_rootarg()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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@xxxxxxxxxxxxxx>
---
 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





[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux