From: Harald Hoyer Date: Fri, 24 Apr 2020 09:05:49 +0000 (+0200) Subject: Install crypto modules in 90kernel-modules X-Git-Tag: 051~172 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=586a56c2877ae8c0b365c3a6c69cd4ff8b27bf0c;p=thirdparty%2Fdracut.git Install crypto modules in 90kernel-modules We don't want to play catch up with hash and encryption algorithms. To be safe, just use the hammer and include all crypto. Fixes https://github.com/dracutdevs/dracut/issues/802 --- diff --git a/modules.d/90btrfs/module-setup.sh b/modules.d/90btrfs/module-setup.sh index 66a254e1f..79f89a503 100755 --- a/modules.d/90btrfs/module-setup.sh +++ b/modules.d/90btrfs/module-setup.sh @@ -26,8 +26,6 @@ depends() { # called by dracut installkernel() { instmods btrfs - # Make sure btfs can use fast crc32c implementations where available (bsc#1011554) - instmods crc32c-intel } # called by dracut diff --git a/modules.d/90crypt/module-setup.sh b/modules.d/90crypt/module-setup.sh index 3ee4c5458..a9dda7341 100755 --- a/modules.d/90crypt/module-setup.sh +++ b/modules.d/90crypt/module-setup.sh @@ -25,11 +25,7 @@ depends() { # called by dracut installkernel() { hostonly="" instmods drbg - arch=$(uname -m) - [[ $arch == x86_64 ]] && arch=x86 - [[ $arch == s390x ]] && arch=s390 - [[ $arch == aarch64 ]] && arch=arm64 - instmods dm_crypt =crypto =drivers/crypto =arch/$arch/crypto + instmods dm_crypt } # called by dracut diff --git a/modules.d/90kernel-modules/module-setup.sh b/modules.d/90kernel-modules/module-setup.sh index bc3810cc4..28d291eb6 100755 --- a/modules.d/90kernel-modules/module-setup.sh +++ b/modules.d/90kernel-modules/module-setup.sh @@ -104,6 +104,15 @@ installkernel() { elif [[ "${host_fs_types[*]}" ]]; then hostonly='' instmods "${host_fs_types[@]}" fi + + arch=${DRACUT_ARCH:-$(uname -m)} + + # We don't want to play catch up with hash and encryption algorithms. + # To be safe, just use the hammer and include all crypto. + [[ $arch == x86_64 ]] && arch=x86 + [[ $arch == s390x ]] && arch=s390 + [[ $arch == aarch64 ]] && arch=arm64 + instmods "=crypto" "=arch/$arch/crypto" "=drivers/crypto" fi : }