Skip to content

Commit d460941

Browse files
ryncsnaafeijoo-suse
authored andcommitted
fix(dracut-init): make require_kernel_modules ignore no kernel build
If --no-kernel is specified, kernel module checking won't work, just skip it. Signed-off-by: Kairui Song <[email protected]>
1 parent 7917d79 commit d460941

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

dracut-init.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,9 @@ require_kernel_modules() {
158158
local _module_name="${moddir##*/}"
159159
local _ret=0
160160

161+
# Ignore kernel module requirement for no-kernel build
162+
[[ $no_kernel == yes ]] && return 0
163+
161164
if [[ $1 == "-m" ]]; then
162165
_module_name="$2"
163166
shift 2

0 commit comments

Comments
 (0)