build/patch/kernel/archive/sunxi-5.10/megous/arm64-xor-Select-32regs-without-benchmark-to-speed-u.patch

39 lines
1.1 KiB
Diff

From 759c84b47f87eb2f2b293df832d5f5378ec06419 Mon Sep 17 00:00:00 2001
From: Ondrej Jirman <megous@megous.com>
Date: Thu, 10 Sep 2020 21:38:28 +0200
Subject: [PATCH 139/351] arm64: xor: Select 32regs without benchmark to speed
up boot
32regs is fastest on Cortex-A53.
Signed-off-by: Ondrej Jirman <megous@megous.com>
---
arch/arm64/include/asm/xor.h | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
diff --git a/arch/arm64/include/asm/xor.h b/arch/arm64/include/asm/xor.h
index 947f6a4f1aa0..4bfa897a45cb 100644
--- a/arch/arm64/include/asm/xor.h
+++ b/arch/arm64/include/asm/xor.h
@@ -57,14 +57,8 @@ static struct xor_block_template xor_block_arm64 = {
.do_4 = xor_neon_4,
.do_5 = xor_neon_5
};
-#undef XOR_TRY_TEMPLATES
-#define XOR_TRY_TEMPLATES \
- do { \
- xor_speed(&xor_block_8regs); \
- xor_speed(&xor_block_32regs); \
- if (cpu_has_neon()) { \
- xor_speed(&xor_block_arm64);\
- } \
- } while (0)
+
+#define XOR_SELECT_TEMPLATE(x) \
+ (&xor_block_32regs)
#endif /* ! CONFIG_KERNEL_MODE_NEON */
--
2.34.0