blob: 350e7d3ec9b129dc771ac6bc4965a486889ebc39 [file] [log] [blame]
From 7be8614176dc79bc242a12b7669f330058e36df6 Mon Sep 17 00:00:00 2001
From: Sam Shih <sam.shih@mediatek.com>
Date: Fri, 2 Jun 2023 13:06:24 +0800
Subject: [PATCH] [adv-feature][999-2550-dual-image-mount-rootfs.patch]
---
init/do_mounts.c | 3 ++-
kernel/boot_param.c | 2 +-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/init/do_mounts.c b/init/do_mounts.c
index cd5fca8aa..2dfc0dac7 100644
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
@@ -576,7 +576,8 @@ void __init mount_root(void)
}
#endif
#ifdef CONFIG_MTD_ROOTFS_ROOT_DEV
- if (!mount_ubi_rootfs())
+ extern bool dual_boot;
+ if (!dual_boot && !mount_ubi_rootfs())
return;
#endif
#ifdef CONFIG_BLOCK
diff --git a/kernel/boot_param.c b/kernel/boot_param.c
index 3dfe828bc..cc0b2b8b0 100644
--- a/kernel/boot_param.c
+++ b/kernel/boot_param.c
@@ -10,7 +10,7 @@
#define BOOT_PARAM_STR_MAX_LEN 256
-static bool dual_boot;
+bool dual_boot;
module_param(dual_boot, bool, 0444);
static bool no_split_rootfs_data;
--
2.34.1