--- a/init/do_mounts.c
+++ b/init/do_mounts.c
-@@ -446,7 +446,30 @@ retry:
+@@ -248,7 +248,30 @@ retry:
out:
put_page(page);
}
#ifdef CONFIG_ROOT_NFS
#define NFSROOT_TIMEOUT_MIN 5
-@@ -579,6 +602,10 @@ void __init mount_root(void)
- return;
- }
- #endif
+@@ -385,6 +408,11 @@ static inline void mount_block_root(char
+
+ void __init mount_root(char *root_device_name)
+ {
+#ifdef CONFIG_MTD_ROOTFS_ROOT_DEV
+ if (!mount_ubi_rootfs())
+ return;
+#endif
- if (ROOT_DEV == 0 && root_device_name && root_fs_names) {
- if (mount_nodev_root() == 0)
- return;
++
+ switch (ROOT_DEV) {
+ case Root_NFS:
+ mount_nfs_root();