lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20201207184835.63538-1-alex_y_xu@yahoo.ca>
Date:   Mon,  7 Dec 2020 13:48:33 -0500
From:   "Alex Xu (Hello71)" <alex_y_xu@...oo.ca>
To:     "Alex Xu (Hello71)" <alex_y_xu@...oo.ca>,
        Dominik Brodowski <linux@...inikbrodowski.net>,
        Song Liu <song@...nel.org>, "Theodore Ts'o" <tytso@....edu>,
        Jens Axboe <axboe@...nel.dk>, linux-kernel@...r.kernel.org
Subject: [PATCH 1/3] init: fall back on mounting raw root

9p/virtio, virtiofs, and others can be mounted with no block device or
userspace helpers.

Signed-off-by: Alex Xu (Hello71) <alex_y_xu@...oo.ca>
---
 init/do_mounts.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/init/do_mounts.c b/init/do_mounts.c
index b5f9604d0c98..8aa38ec0bfec 100644
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
@@ -568,7 +568,7 @@ void __init mount_root(void)
 	}
 #endif
 #ifdef CONFIG_BLOCK
-	{
+	if (ROOT_DEV != 0) {
 		int err = create_dev("/dev/root", ROOT_DEV);
 
 		if (err < 0)
@@ -576,6 +576,7 @@ void __init mount_root(void)
 		mount_block_root("/dev/root", root_mountflags);
 	}
 #endif
+	mount_block_root(saved_root_name, root_mountflags);
 }
 
 /*
-- 
2.29.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ