summaryrefslogtreecommitdiffstats
path: root/providers
diff options
context:
space:
mode:
authorsdlyyxy <sdlyyxy@icloud.com>2023-07-15 23:26:05 +0800
committerPauli <pauli@openssl.org>2023-07-21 10:19:19 +1000
commitba9472c1c121b13e48f7c198d3fe9871a86e664c (patch)
treeb4abbca5974d69bd1bfd8c1a43cb02c6f0ed4753 /providers
parent08e6eb216c9d65d502dc136a40e1c0adaefab759 (diff)
Update with `ARMV8_HAVE_SHA3_AND_WORTH_USING`
Reviewed-by: Tom Cosgrove <tom.cosgrove@arm.com> Reviewed-by: Paul Dale <pauli@openssl.org> (Merged from https://github.com/openssl/openssl/pull/21398)
Diffstat (limited to 'providers')
-rw-r--r--providers/implementations/digests/sha3_prov.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/providers/implementations/digests/sha3_prov.c b/providers/implementations/digests/sha3_prov.c
index a03df0b7fc..7bb0bff851 100644
--- a/providers/implementations/digests/sha3_prov.c
+++ b/providers/implementations/digests/sha3_prov.c
@@ -271,18 +271,14 @@ static PROV_SHA3_METHOD sha3_ARMSHA3_md =
armsha3_sha3_absorb,
generic_sha3_final
};
-/* Users can switch back to the generic code by clearing either of the bits */
-# define ARM_SHA3_CAPABLE \
- ((OPENSSL_armcap_P & ARMV8_SHA3) && \
- (OPENSSL_armcap_P & ARMV8_WORTH_USING_SHA3))
# define SHA3_SET_MD(uname, typ) \
- if (ARM_SHA3_CAPABLE) { \
+ if (OPENSSL_armcap_P & ARMV8_HAVE_SHA3_AND_WORTH_USING) { \
ctx->meth = sha3_ARMSHA3_md; \
} else { \
ctx->meth = sha3_generic_md; \
}
# define KMAC_SET_MD(bitlen) \
- if (ARM_SHA3_CAPABLE) { \
+ if (OPENSSL_armcap_P & ARMV8_HAVE_SHA3_AND_WORTH_USING) { \
ctx->meth = sha3_ARMSHA3_md; \
} else { \
ctx->meth = sha3_generic_md; \