28ab1c
From be22f63f7d7c62d88edb5a24dccfff2774094773 Mon Sep 17 00:00:00 2001
28ab1c
From: =?UTF-8?q?Zolt=C3=A1n=20B=C3=B6sz=C3=B6rm=C3=A9nyi?= <zboszor@pr.hu>
28ab1c
Date: Tue, 19 Jan 2021 15:17:05 +0100
28ab1c
Subject: [PATCH] fix(99squash): use kernel config instead of modprobe to check
28ab1c
 modules
28ab1c
MIME-Version: 1.0
28ab1c
Content-Type: text/plain; charset=UTF-8
28ab1c
Content-Transfer-Encoding: 8bit
28ab1c
28ab1c
Signed-off-by: Zoltán Böszörményi <zboszor@pr.hu>
28ab1c
(cherry picked from commit 911c2de9c34a2e96be3973954d368d3a14eb6785)
28ab1c
28ab1c
Resolves: #1959336
28ab1c
---
28ab1c
 modules.d/99squash/module-setup.sh | 6 +++---
28ab1c
 1 file changed, 3 insertions(+), 3 deletions(-)
28ab1c
28ab1c
diff --git a/modules.d/99squash/module-setup.sh b/modules.d/99squash/module-setup.sh
28ab1c
index e2fe3dd4..d3680d63 100644
28ab1c
--- a/modules.d/99squash/module-setup.sh
28ab1c
+++ b/modules.d/99squash/module-setup.sh
28ab1c
@@ -11,9 +11,9 @@ check() {
28ab1c
         return 1
28ab1c
     fi
28ab1c
 
28ab1c
-    for i in squashfs loop overlay; do
28ab1c
-        if ! check_kernel_module $i; then
28ab1c
-            derror "dracut-squash module requires kernel module $i"
28ab1c
+    for i in CONFIG_SQUASHFS CONFIG_BLK_DEV_LOOP CONFIG_OVERLAY_FS ; do
28ab1c
+        if ! check_kernel_config $i; then
28ab1c
+            derror "dracut-squash module requires kernel configuration $i (y or m)"
28ab1c
             return 1
28ab1c
         fi
28ab1c
     done
28ab1c