ramips: mtk-eip93: fix build with kernel <= 5.10

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
Tianling Shen 2022-03-09 12:32:55 +08:00
parent e8c7e1f897
commit 906aeaead2
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
2 changed files with 10 additions and 3 deletions

View File

@ -35,8 +35,8 @@ config CRYPTO_DEV_EIP93_DES
crypto to the EIP-93 crypto engine.
config CRYPTO_DEV_EIP93_AEAD
bool "Register AEAD algorithm with the Crypto API"
default y
bool "Register AEAD algorithm with the Crypto API"
default y
select CRYPTO_DEV_EIP93_HMAC
select CRYPTO_AEAD
select CRYPTO_AUTHENC
@ -44,6 +44,6 @@ config CRYPTO_DEV_EIP93_AEAD
select CRYPTO_SHA1
select CRYPTO_SHA256
help
Selecting this will offload AEAD authenc(hmac(x), cipher(y))
Selecting this will offload AEAD authenc(hmac(x), cipher(y))
crypto to the EIP-93 crypto engine.
endif

View File

@ -5,6 +5,9 @@
* Richard van Schagen <vschagen@icloud.com>
*/
#include <linux/version.h>
#include <linux/iversion.h>
#include <crypto/aead.h>
#include <crypto/aes.h>
#include <crypto/authenc.h>
@ -13,8 +16,12 @@
#include <crypto/internal/aead.h>
#include <crypto/md5.h>
#include <crypto/null.h>
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0)
#include <crypto/sha1.h>
#include <crypto/sha2.h>
#else
#include <crypto/sha.h>
#endif
#if IS_ENABLED(CONFIG_CRYPTO_DEV_EIP93_DES)
#include <crypto/internal/des.h>