From 9bcd6768fd907b2172330d4897c8330fb12ea02e Mon Sep 17 00:00:00 2001 From: Jerry Yu Date: Fri, 3 Apr 2020 16:52:47 +0800 Subject: [PATCH] crc32:Adjust hardware folding algorithm flags Hardware folding algorithm depend on CRC32 and PMULL instruction. And it should match both flags . Change-Id: I361068402db1fe6d7c0bd8d2c7048f1d94880233 Signed-off-by: Jerry Yu --- crc/aarch64/crc_aarch64_dispatcher.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/crc/aarch64/crc_aarch64_dispatcher.c b/crc/aarch64/crc_aarch64_dispatcher.c index 3fada02..1df2833 100644 --- a/crc/aarch64/crc_aarch64_dispatcher.c +++ b/crc/aarch64/crc_aarch64_dispatcher.c @@ -73,9 +73,9 @@ DEFINE_INTERFACE_DISPATCHER(crc32_iscsi) case MICRO_ARCH_ID(ARM, NEOVERSE_N1): return PROVIDER_INFO(crc32c_mix_neoverse_n1); } - } - if (auxval & HWCAP_CRC32) return PROVIDER_INFO(crc32_iscsi_refl_hw_fold); + } + if (auxval & HWCAP_PMULL) { return PROVIDER_INFO(crc32_iscsi_refl_pmull); } @@ -98,9 +98,9 @@ DEFINE_INTERFACE_DISPATCHER(crc32_gzip_refl) case MICRO_ARCH_ID(ARM, NEOVERSE_N1): return PROVIDER_INFO(crc32_mix_neoverse_n1); } - } - if (auxval & HWCAP_CRC32) return PROVIDER_INFO(crc32_gzip_refl_hw_fold); + } + if (auxval & HWCAP_PMULL) return PROVIDER_INFO(crc32_gzip_refl_pmull);