[PATCH 2/2] kernel: crypto: add cavium cptpf module
Daniel Danzberger
daniel at dd-wrt.com
Sun Apr 18 08:46:54 BST 2021
Provides hardware crypto support for some cavium platforms like the
octeontx. Cryptodev support is also enabled for use from userspace.
Requires 2 firmwares (cpt8x-mc-ae.out + cpt8x-mc-se.out).
Provided by those packages:
cavium-firmware-cpt-ae
cavium-firmware-cpt-se
Supported ciphers:
-
root at OpenWrt:/# cat /proc/crypto | grep driver
driver : cavium-ecb-des3_ede
driver : cavium-cbc-des3_ede
driver : cavium-cfb-aes
driver : cavium-ecb-aes
driver : cavium-cbc-aes
driver : cavium-xts-aes
-
Signed-off-by: Daniel Danzberger <daniel at dd-wrt.com>
---
package/kernel/linux/modules/crypto.mk | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk
index 2775239e52..3da1dcab8c 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -944,6 +944,27 @@ endef
KernelPackage/crypto-sha512/tegra=$(KernelPackage/crypto-sha512/arm)
+define KernelPackage/crypto-hw-cavium-cpt
+ TITLE:= OcteonTX Crypto Accelerator
+ DEPENDS:= \
+ +kmod-crypto-manager \
+ +cavium-firmware-cpt-ae \
+ +cavium-firmware-cpt-se
+ KCONFIG:= \
+ CONFIG_CRYPTO_HW=y \
+ CONFIG_CRYPTO_DEV_CPT \
+ CONFIG_CRYPTO_DEV_OCTEONTX_CPT \
+ CONFIG_CAVIUM_CPT \
+
+ FILES:=$(LINUX_DIR)/drivers/crypto/cavium/cpt/cptpf.ko \
+ $(LINUX_DIR)/drivers/crypto/cavium/cpt/cptvf.ko
+ AUTOLOAD:=$(call AutoLoad,90,cptpf cptvf)
+ $(call AddDepends/crypto)
+endef
+
+$(eval $(call KernelPackage,crypto-hw-cavium-cpt))
+
+
define KernelPackage/crypto-sha512/x86/64
FILES+=$(LINUX_DIR)/arch/x86/crypto/sha512-ssse3.ko
AUTOLOAD+=$(call AutoLoad,09,sha512-ssse3)
--
2.30.2
More information about the openwrt-devel
mailing list