From 35b04bafa187a99044ced7df9eb9148bc771be64 Mon Sep 17 00:00:00 2001 From: Weijie Gao Date: Sun, 3 Mar 2024 22:07:29 +0800 Subject: [PATCH] kernel: modules: crypto: adapt for kernel 6.6 Adapt crypto kmods for building under kernel 6.6: * mpi.ko moved from lib/mpi/mpi.ko to lib/crypto/mpi/mpi.ko * jitterentropy_rng requires SHA3 support for kernel 6.6 Signed-off-by: Robert Marko Signed-off-by: Tan Zien Signed-off-by: Weijie Gao --- package/kernel/linux/modules/crypto.mk | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk index b7cecb8919..f61f258603 100644 --- a/package/kernel/linux/modules/crypto.mk +++ b/package/kernel/linux/modules/crypto.mk @@ -39,7 +39,8 @@ define KernelPackage/crypto-aead TITLE:=CryptoAPI AEAD support KCONFIG:= \ CONFIG_CRYPTO_AEAD \ - CONFIG_CRYPTO_AEAD2 + CONFIG_CRYPTO_AEAD2 \ + CONFIG_CRYPTO_GENIV FILES:= \ $(LINUX_DIR)/crypto/aead.ko \ $(LINUX_DIR)/crypto/geniv.ko @@ -216,7 +217,7 @@ $(eval $(call KernelPackage,crypto-ecb)) define KernelPackage/crypto-ecdh TITLE:=ECDH algorithm - DEPENDS:=+kmod-crypto-kpp + DEPENDS:=+kmod-crypto-kpp +kmod-crypto-rng KCONFIG:= CONFIG_CRYPTO_ECDH FILES:= \ $(LINUX_DIR)/crypto/ecdh_generic.ko \ @@ -846,7 +847,8 @@ define KernelPackage/crypto-rsa KCONFIG:= CONFIG_CRYPTO_RSA HIDDEN:=1 FILES:= \ - $(LINUX_DIR)/lib/mpi/mpi.ko \ + $(LINUX_DIR)/lib/mpi/mpi.ko@lt6.5 \ + $(LINUX_DIR)/lib/crypto/mpi/mpi.ko@ge6.5 \ $(LINUX_DIR)/crypto/akcipher.ko \ $(LINUX_DIR)/crypto/rsa_generic.ko AUTOLOAD:=$(call AutoLoad,10,rsa_generic) @@ -870,7 +872,7 @@ $(eval $(call KernelPackage,crypto-rmd160)) define KernelPackage/crypto-rng TITLE:=CryptoAPI random number generation - DEPENDS:=+kmod-crypto-hash +kmod-crypto-hmac +kmod-crypto-sha512 + DEPENDS:=+kmod-crypto-hash +kmod-crypto-hmac +kmod-crypto-sha512 +LINUX_6_6:kmod-crypto-sha3 KCONFIG:= \ CONFIG_CRYPTO_DRBG \ CONFIG_CRYPTO_DRBG_HMAC=y \ -- 2.30.2