From 9e91815487925676989ce544621d637f4942a550 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrien=20Gallou=C3=ABt?= Date: Thu, 14 May 2020 11:12:17 +0000 Subject: [PATCH] Improve kernel section MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Adrien Gallouët --- README.md | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 70414e9..78050a2 100644 --- a/README.md +++ b/README.md @@ -56,22 +56,29 @@ Note that `/init` mounts `cgroup2` as `/sys/fs/cgroup` and not the old `cgroup`. ## Kernel configuration -A minimum kernel configuration would look like this: +A minimal kernel configuration to enable all features of `/init` would look like this: CONFIG_BLK_DEV_INITRD=y - CONFIG_INITRAMFS_SOURCE="$PWD/root" + CONFIG_INITRAMFS_SOURCE= # root directory with /init CONFIG_BINFMT_ELF=y CONFIG_BINFMT_SCRIPT=y CONFIG_DEVTMPFS=y CONFIG_PROC_FS=y CONFIG_SYSFS=y + +Since all logs go into the kernel, it's a good idea to increase the size of the log buffer: + CONFIG_LOG_BUF_SHIFT=24 +Required for updates: + CONFIG_RELOCATABLE=y CONFIG_CRYPTO=y CONFIG_CRYPTO_SHA256=y CONFIG_KEXEC_FILE=y +Not mandatory but useful to see what's going on :) + CONFIG_PRINTK=y CONFIG_TTY=y CONFIG_SERIAL_8250=y