diff --git a/sys/crypto/sha2/sha256c.c b/sys/crypto/sha2/sha256c.c --- a/sys/crypto/sha2/sha256c.c +++ b/sys/crypto/sha2/sha256c.c @@ -206,12 +206,8 @@ DEFINE_UIFUNC(static, void, SHA256_Transform, (uint32_t * state, const unsigned char block[64])) { - u_long hwcap; - - if (elf_aux_info(AT_HWCAP, &hwcap, sizeof(hwcap)) == 0) { - if ((hwcap & HWCAP_SHA2) != 0) - return (SHA256_Transform_arm64); - } + if ((at_hwcap & HWCAP_SHA2) != 0) + return (SHA256_Transform_arm64); return (SHA256_Transform_c); } diff --git a/sys/crypto/sha2/sha512c.c b/sys/crypto/sha2/sha512c.c --- a/sys/crypto/sha2/sha512c.c +++ b/sys/crypto/sha2/sha512c.c @@ -236,13 +236,8 @@ DEFINE_UIFUNC(static, void, SHA512_Transform, (uint64_t * state, const unsigned char block[SHA512_BLOCK_LENGTH])) { - u_long hwcap; - - if (elf_aux_info(AT_HWCAP, &hwcap, sizeof(hwcap)) == 0) { - if ((hwcap & HWCAP_SHA512) != 0) { - return (SHA512_Transform_arm64); - } - } + if ((at_hwcap & HWCAP_SHA512) != 0) + return (SHA512_Transform_arm64); return (SHA512_Transform_c); }