From fe2767219e22eda853cb1ad30c44c49afc1bed66 Mon Sep 17 00:00:00 2001 From: dzwdz Date: Thu, 10 Aug 2023 00:07:35 +0200 Subject: user/fs: no longer inject MOUNT_ATs by default arguably the wrong choice from an usability standpoint, but the right choice from a performance standpoint. there's definitely a nicer way to do this --- src/user/bootstrap/main.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src/user/bootstrap') diff --git a/src/user/bootstrap/main.c b/src/user/bootstrap/main.c index 348486c..d27da39 100644 --- a/src/user/bootstrap/main.c +++ b/src/user/bootstrap/main.c @@ -18,8 +18,16 @@ int main(void) { setprogname("bootstrap"); _sys_mount(HANDLE_PROCFS, "/proc/", strlen("/proc/")); - MOUNT_AT("/") { fs_dirinject("/proc/"); } - MOUNT_AT("/init/") { tar_driver(&_initrd); } + MOUNT_AT("/") { + fs_dirinject2((const char*[]) { + "/proc/", + "/init/", + NULL + }); + } + MOUNT_AT("/init/") { + tar_driver(&_initrd); + } const char *initpath = "bin/amd64/init"; char *initargv[] = {"init", NULL}; -- cgit v1.2.3