1
0
mirror of https://github.com/google/cpu_features.git synced 2025-07-01 21:31:15 +02:00

Update AArch64 features to Linux 5.17. (#237)

This commit is contained in:
Tamas Zsoldos
2022-04-27 10:26:29 +02:00
committed by GitHub
parent 7fe96b1d3d
commit b04a9daf71
4 changed files with 16 additions and 1 deletions

View File

@ -72,6 +72,9 @@ typedef struct {
int rng : 1; // True random number generator support.
int bti : 1; // Branch target identification.
int mte : 1; // Memory tagging extension.
int ecv : 1; // Enhanced counter virtualization.
int afp : 1; // Alternate floating-point behaviour.
int rpres : 1; // 12-bit reciprocal (square root) estimate precision.
// Make sure to update Aarch64FeaturesEnum below if you add a field here.
} Aarch64Features;
@ -141,6 +144,9 @@ typedef enum {
AARCH64_RNG,
AARCH64_BTI,
AARCH64_MTE,
AARCH64_ECV,
AARCH64_AFP,
AARCH64_RPRES,
AARCH64_LAST_,
} Aarch64FeaturesEnum;

View File

@ -80,6 +80,9 @@ CPU_FEATURES_START_CPP_NAMESPACE
#define AARCH64_HWCAP2_RNG (1UL << 16)
#define AARCH64_HWCAP2_BTI (1UL << 17)
#define AARCH64_HWCAP2_MTE (1UL << 18)
#define AARCH64_HWCAP2_ECV (1UL << 19)
#define AARCH64_HWCAP2_AFP (1UL << 20)
#define AARCH64_HWCAP2_RPRES (1UL << 21)
// http://elixir.free-electrons.com/linux/latest/source/arch/arm/include/uapi/asm/hwcap.h
#define ARM_HWCAP_SWP (1UL << 0)