mirror of
https://github.com/hanwckf/immortalwrt-mt798x.git
synced 2025-01-09 02:43:53 +08:00
395ebd8ba3
(cherry picked from commit 7fc2fd764114b639a59609442d3b1fbc42a9a1f6)
49 lines
1.1 KiB
Diff
49 lines
1.1 KiB
Diff
--- 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"
|