mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
mtk-eip93: update to latest git HEAD
This commit is contained in:
parent
4132115fc2
commit
fc044f23f2
@ -12,12 +12,11 @@ PKG_NAME:=mtk-eip93
|
||||
PKG_RELEASE:=1.3
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_DATE:=2020-12-10
|
||||
PKG_SOURCE_URL:=https://github.com/vschagen/mtk-eip93.git
|
||||
PKG_SOURCE_VERSION:=bb5fd1c88a8a74de06b70c281bceeb14d0d960ef
|
||||
PKG_MIRROR_HASH:=d2a4c5da7fb695e575de4b4335b73dcbfea195ef76791133d36287065a66386b
|
||||
PKG_SOURCE_VERSION:=ca08387bf8352652129019bb19e2423ab313d5cb
|
||||
PKG_MIRROR_HASH:=4505ee2a175a6cf77a1a3b4fa7bf188da8f8b47894e5afa62c8cb008fbfa15ed
|
||||
|
||||
MAKE_PATH:=src
|
||||
MAKE_PATH:=crypto/mtk-eip93
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
@ -32,9 +31,8 @@ define KernelPackage/crypto-hw-eip93
|
||||
+kmod-crypto-md5 \
|
||||
+kmod-crypto-sha1 \
|
||||
+kmod-crypto-sha256
|
||||
KCONFIG:=
|
||||
TITLE:=MTK EIP93 crypto module.
|
||||
FILES:=$(PKG_BUILD_DIR)/src/crypto-hw-eip93.ko
|
||||
FILES:=$(PKG_BUILD_DIR)/crypto/mtk-eip93/crypto-hw-eip93.ko
|
||||
AUTOLOAD:=$(call AutoProbe,crypto-hw-eip93)
|
||||
endef
|
||||
|
||||
@ -45,9 +43,22 @@ It enables DES/3DES/AES ECB/CBC/CTR and
|
||||
IPSEC offload with authenc(hmac(sha1/sha256), aes/cbc/rfc3686)
|
||||
endef
|
||||
|
||||
PKG_EXTRA_KCONFIG:= \
|
||||
CONFIG_CRYPTO_DEV_EIP93=m \
|
||||
CONFIG_CRYPTO_DEV_EIP93_AEAD=y \
|
||||
CONFIG_CRYPTO_DEV_EIP93_AES=y \
|
||||
CONFIG_CRYPTO_DEV_EIP93_DES=y \
|
||||
CONFIG_CRYPTO_DEV_EIP93_HMAC=y \
|
||||
CONFIG_CRYPTO_DEV_EIP93_SKCIPHER=y
|
||||
|
||||
PKG_EXTRA_CFLAGS:= \
|
||||
$(patsubst CONFIG_%, -DCONFIG_%=1, $(patsubst %=y,%,$(filter %=y,$(PKG_EXTRA_KCONFIG))))
|
||||
|
||||
MAKE_OPTS:= \
|
||||
$(KERNEL_MAKE_FLAGS) \
|
||||
M="$(PKG_BUILD_DIR)/src"
|
||||
M="$(PKG_BUILD_DIR)/crypto/mtk-eip93" \
|
||||
$(PKG_EXTRA_KCONFIG) \
|
||||
EXTRA_CFLAGS="$(PKG_EXTRA_CFLAGS)"
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C "$(LINUX_DIR)" \
|
||||
|
@ -1,46 +0,0 @@
|
||||
From dff6ffb8ea3d556df1bf15407783af19b239d3ec Mon Sep 17 00:00:00 2001
|
||||
From: W_Y_CPP <383152993@qq.com>
|
||||
Date: Sat, 23 Apr 2022 18:03:27 +0900
|
||||
Subject: [PATCH] fix build with kernel 5.15
|
||||
|
||||
---
|
||||
src/eip93-cipher.c | 7 +++++++
|
||||
src/eip93-core.h | 3 ++-
|
||||
2 files changed, 9 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/eip93-cipher.c b/src/eip93-cipher.c
|
||||
index c99cb05..1618954 100644
|
||||
--- a/src/eip93-cipher.c
|
||||
+++ b/src/eip93-cipher.c
|
||||
@@ -16,7 +16,14 @@
|
||||
#include <crypto/md5.h>
|
||||
#include <crypto/null.h>
|
||||
#include <crypto/scatterwalk.h>
|
||||
+
|
||||
+#include <linux/version.h>
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 15, 0)
|
||||
+#include <crypto/sha1.h>
|
||||
+#include <crypto/sha2.h>
|
||||
+#else
|
||||
#include <crypto/sha.h>
|
||||
+#endif
|
||||
|
||||
#include <linux/dma-mapping.h>
|
||||
#include <linux/dmapool.h>
|
||||
diff --git a/src/eip93-core.h b/src/eip93-core.h
|
||||
index c391565..bfa1879 100644
|
||||
--- a/src/eip93-core.h
|
||||
+++ b/src/eip93-core.h
|
||||
@@ -14,7 +14,8 @@
|
||||
#include <crypto/internal/hash.h>
|
||||
#include <crypto/internal/rng.h>
|
||||
#include <crypto/internal/skcipher.h>
|
||||
-
|
||||
+#include <linux/of.h>
|
||||
+#include <linux/interrupt.h>
|
||||
/**
|
||||
* struct mtk_device - crypto engine device structure
|
||||
*/
|
||||
--
|
||||
2.17.1
|
||||
|
@ -1,25 +0,0 @@
|
||||
From 5cb6ed54f462618a788b9b7cd3baab13c48fd39c Mon Sep 17 00:00:00 2001
|
||||
From: W_Y_CPP <383152993@qq.com>
|
||||
Date: Mon, 28 Feb 2022 05:34:40 -0500
|
||||
Subject: [PATCH] fix build error
|
||||
|
||||
---
|
||||
src/eip93-common.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/eip93-common.h b/src/eip93-common.h
|
||||
index 5781494ae..4cab86018 100644
|
||||
--- a/src/eip93-common.h
|
||||
+++ b/src/eip93-common.h
|
||||
@@ -9,6 +9,8 @@
|
||||
#define _COMMON_H_
|
||||
|
||||
#include <linux/bits.h>
|
||||
+#include <linux/device.h>
|
||||
+#include <linux/dma-mapping.h>
|
||||
|
||||
#define MTK_RING_SIZE 256
|
||||
#define MTK_RING_BUSY 224
|
||||
--
|
||||
2.17.1
|
||||
|
@ -0,0 +1,48 @@
|
||||
--- a/crypto/mtk-eip93/eip93-aead.c
|
||||
+++ b/crypto/mtk-eip93/eip93-aead.c
|
||||
@@ -13,8 +13,6 @@
|
||||
#include <crypto/internal/aead.h>
|
||||
#include <crypto/md5.h>
|
||||
#include <crypto/null.h>
|
||||
-#include <crypto/sha1.h>
|
||||
-#include <crypto/sha2.h>
|
||||
|
||||
#if IS_ENABLED(CONFIG_CRYPTO_DEV_EIP93_DES)
|
||||
#include <crypto/internal/des.h>
|
||||
@@ -22,6 +20,14 @@
|
||||
|
||||
#include <linux/crypto.h>
|
||||
#include <linux/dma-mapping.h>
|
||||
+#include <linux/version.h>
|
||||
+
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 11, 0)
|
||||
+#include <crypto/sha.h>
|
||||
+#else
|
||||
+#include <crypto/sha1.h>
|
||||
+#include <crypto/sha2.h>
|
||||
+#endif
|
||||
|
||||
#include "eip93-aead.h"
|
||||
#include "eip93-cipher.h"
|
||||
--- a/crypto/mtk-eip93/eip93-common.c
|
||||
+++ b/crypto/mtk-eip93/eip93-common.c
|
||||
@@ -8,11 +8,17 @@
|
||||
#include <crypto/aes.h>
|
||||
#include <crypto/ctr.h>
|
||||
#include <crypto/hmac.h>
|
||||
-#include <crypto/sha1.h>
|
||||
-#include <crypto/sha2.h>
|
||||
#include <linux/delay.h>
|
||||
#include <linux/dma-mapping.h>
|
||||
#include <linux/scatterlist.h>
|
||||
+#include <linux/version.h>
|
||||
+
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 11, 0)
|
||||
+#include <crypto/sha.h>
|
||||
+#else
|
||||
+#include <crypto/sha1.h>
|
||||
+#include <crypto/sha2.h>
|
||||
+#endif
|
||||
|
||||
#include "eip93-cipher.h"
|
||||
#include "eip93-common.h"
|
Loading…
Reference in New Issue
Block a user