From 2218e13cd66e5142352e91eb47b792e8d24d74cf Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Tue, 5 Apr 2016 09:20:52 +0000 Subject: setup-disk: only load filesystem module if needed The filesystem may be compiled into the kernel --- setup-disk.in | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/setup-disk.in b/setup-disk.in index ea3c590..1cfb8e6 100644 --- a/setup-disk.in +++ b/setup-disk.in @@ -448,7 +448,9 @@ init_progs() { for fs in $BOOTFS $ROOTFS $VARFS; do # we need load btrfs module early to avoid the error message: # 'failed to open /dev/btrfs-control' - modprobe $fs + if ! grep -q -w "$fs" /proc/filesystems; then + modprobe $fs + fi case $fs in xfs) fstools="$fstools xfsprogs";; -- cgit v1.2.3