kernel: Add crypto libraries to modules
authorHauke Mehrtens <[email protected]>
Fri, 31 Jan 2020 12:32:03 +0000 (13:32 +0100)
committerKoen Vandeputte <[email protected]>
Fri, 28 Feb 2020 16:50:46 +0000 (17:50 +0100)
In kernel 5.3 and 5.4 some crypto modules were split into two modules,
one implementing the crypto algorithm and the other integrating it
into the Linux crypto framework.

Adapt OpenWrt to support this split.

Signed-off-by: Hauke Mehrtens <[email protected]>
package/kernel/linux/modules/crypto.mk

index 26873b404a7629752fcf8a70f522a74f197203dd..be2182fd8b829af4a5db3dd6bef47b03e38c0231 100644 (file)
@@ -169,7 +169,9 @@ $(eval $(call KernelPackage,crypto-deflate))
 define KernelPackage/crypto-des
   TITLE:=DES/3DES cipher CryptoAPI module
   KCONFIG:=CONFIG_CRYPTO_DES
-  FILES:=$(LINUX_DIR)/crypto/des_generic.ko
+  FILES:= \
+       $(LINUX_DIR)/crypto/des_generic.ko \
+       $(LINUX_DIR)/lib/crypto/[email protected]
   AUTOLOAD:=$(call AutoLoad,09,des_generic)
   $(call AddDepends/crypto)
 endef
@@ -194,7 +196,8 @@ define KernelPackage/crypto-ecdh
   DEPENDS:=+kmod-crypto-kpp
   KCONFIG:= CONFIG_CRYPTO_ECDH
   FILES:= \
-       $(LINUX_DIR)/crypto/ecdh_generic.ko
+       $(LINUX_DIR)/crypto/ecdh_generic.ko \
+       $(LINUX_DIR)/crypto/[email protected]
   AUTOLOAD:=$(call AutoLoad,10,ecdh_generic)
   $(call AddDepends/crypto)
 endef
@@ -695,7 +698,9 @@ define KernelPackage/crypto-sha256
        CONFIG_CRYPTO_SHA256 \
        CONFIG_CRYPTO_SHA256_OCTEON \
        CONFIG_CRYPTO_SHA256_SSSE3
-  FILES:=$(LINUX_DIR)/crypto/sha256_generic.ko
+  FILES:= \
+       $(LINUX_DIR)/crypto/sha256_generic.ko \
+       $(LINUX_DIR)/lib/crypto/[email protected]
   AUTOLOAD:=$(call AutoLoad,09,sha256_generic)
   $(call AddDepends/crypto)
 endef