[PATCH 12/12] efi: mount efivarfs by default if enabled

Lucas Stach l.stach at pengutronix.de
Mon Dec 8 05:42:39 PST 2014


Signed-off-by: Lucas Stach <l.stach at pengutronix.de>
---
 common/startup.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/common/startup.c b/common/startup.c
index 01718146ff69..0d62f16f32f6 100644
--- a/common/startup.c
+++ b/common/startup.c
@@ -50,6 +50,12 @@ static int mount_root(void)
 	mount("none", "ramfs", "/", NULL);
 	mkdir("/dev", 0);
 	mount("none", "devfs", "/dev", NULL);
+
+	if (IS_ENABLED(CONFIG_FS_EFIVARFS)) {
+		mkdir("/efivars", 0);
+		mount("none", "efivarfs", "/efivars", NULL);
+	}
+
 	return 0;
 }
 fs_initcall(mount_root);
-- 
2.1.3




More information about the barebox mailing list