linux/debian/patches/bugfix/all/fs-add-module_softdep-decla...

78 lines
2.7 KiB
Diff

From: Ben Hutchings <ben@decadent.org.uk>
Date: Wed, 13 Apr 2016 21:48:06 +0100
Subject: fs: Add MODULE_SOFTDEP declarations for hard-coded crypto drivers
Bug-Debian: https://bugs.debian.org/819725
Forwarded: http://mid.gmane.org/20160517133631.GF7555@decadent.org.uk
This helps initramfs builders and other tools to find the full
dependencies of a module.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
[Lukas Wunner: Forward-ported to 4.11: drop parts applied upstream]
---
Index: linux/fs/btrfs/super.c
===================================================================
--- linux.orig/fs/btrfs/super.c
+++ linux/fs/btrfs/super.c
@@ -2514,3 +2514,4 @@ late_initcall(init_btrfs_fs);
module_exit(exit_btrfs_fs)
MODULE_LICENSE("GPL");
+MODULE_SOFTDEP("pre: crypto-crc32c");
Index: linux/fs/crypto/crypto.c
===================================================================
--- linux.orig/fs/crypto/crypto.c
+++ linux/fs/crypto/crypto.c
@@ -502,3 +502,4 @@ static void __exit fscrypt_exit(void)
module_exit(fscrypt_exit);
MODULE_LICENSE("GPL");
+MODULE_SOFTDEP("pre: crypto-aes crypto-ecb");
Index: linux/fs/ext4/super.c
===================================================================
--- linux.orig/fs/ext4/super.c
+++ linux/fs/ext4/super.c
@@ -6082,6 +6082,6 @@ static void __exit ext4_exit_fs(void)
MODULE_AUTHOR("Remy Card, Stephen Tweedie, Andrew Morton, Andreas Dilger, Theodore Ts'o and others");
MODULE_DESCRIPTION("Fourth Extended Filesystem");
MODULE_LICENSE("GPL");
-MODULE_SOFTDEP("pre: crc32c");
+MODULE_SOFTDEP("pre: crypto-crc32c");
module_init(ext4_init_fs)
module_exit(ext4_exit_fs)
Index: linux/fs/f2fs/super.c
===================================================================
--- linux.orig/fs/f2fs/super.c
+++ linux/fs/f2fs/super.c
@@ -3357,4 +3357,5 @@ module_exit(exit_f2fs_fs)
MODULE_AUTHOR("Samsung Electronics's Praesto Team");
MODULE_DESCRIPTION("Flash Friendly File System");
MODULE_LICENSE("GPL");
+MODULE_SOFTDEP("pre: crypto-crc32c");
Index: linux/fs/jbd2/journal.c
===================================================================
--- linux.orig/fs/jbd2/journal.c
+++ linux/fs/jbd2/journal.c
@@ -2745,6 +2745,7 @@ static void __exit journal_exit(void)
}
MODULE_LICENSE("GPL");
+MODULE_SOFTDEP("pre: crypto-crc32c");
module_init(journal_init);
module_exit(journal_exit);
Index: linux/fs/nfsd/nfsctl.c
===================================================================
--- linux.orig/fs/nfsd/nfsctl.c
+++ linux/fs/nfsd/nfsctl.c
@@ -1337,5 +1337,8 @@ static void __exit exit_nfsd(void)
MODULE_AUTHOR("Olaf Kirch <okir@monad.swb.de>");
MODULE_LICENSE("GPL");
+#ifdef CONFIG_NFSD_V4
+MODULE_SOFTDEP("pre: crypto-md5");
+#endif
module_init(init_nfsd)
module_exit(exit_nfsd)