9#include <openssl/types.h>
10#include "crypto/arm_arch.h"
24#define GET_BITFIELD(value, shift, mask) \
25 ((value >> shift) & mask)
27UINT32 OPENSSL_armcap_P = 0;
37 Isar0 = ArmReadIdAA64Isar0Reg ();
40 OPENSSL_armcap_P |= ARMV8_CPUID;
42 OPENSSL_armcap_P |= ARMV7_TICK;
47 OPENSSL_armcap_P |= ARMV7_NEON;
51 ARM_ID_AA64ISAR0_EL1_AES_SHIFT,
52 ARM_ID_AA64ISAR0_EL1_AES_MASK
55 OPENSSL_armcap_P |= ARMV8_AES;
60 ARM_ID_AA64ISAR0_EL1_SHA1_SHIFT,
61 ARM_ID_AA64ISAR0_EL1_SHA1_MASK
64 OPENSSL_armcap_P |= ARMV8_SHA1;
69 ARM_ID_AA64ISAR0_EL1_SHA2_SHIFT,
70 ARM_ID_AA64ISAR0_EL1_SHA2_MASK
73 OPENSSL_armcap_P |= ARMV8_SHA256;
78 ARM_ID_AA64ISAR0_EL1_AES_SHIFT,
79 ARM_ID_AA64ISAR0_EL1_AES_MASK
80 ) >= ARM_ID_AA64ISAR0_EL1_AES_FEAT_PMULL_MASK)
82 OPENSSL_armcap_P |= ARMV8_PMULL;
87 ARM_ID_AA64ISAR0_EL1_SHA2_SHIFT,
88 ARM_ID_AA64ISAR0_EL1_SHA2_MASK
89 ) >= ARM_ID_AA64ISAR0_EL1_SHA2_FEAT_SHA512_MASK)
91 OPENSSL_armcap_P |= ARMV8_SHA512;
106 return (UINT32)ArmReadCntPctReg ();
#define GET_BITFIELD(value, shift, mask)
uint32_t OPENSSL_rdtsc(void)
VOID OPENSSL_cpuid_setup(VOID)