[PATCH v2 0/3] arm64: Add two HWCAPs for Arm v8.7 FP behaviour

Joey Gouly joey.gouly at arm.com
Tue Dec 7 04:42:23 PST 2021


This series adds new HWCAPs for two Arm v8.7 features:
  - FEAT_AFP: Alternate floating-point behavior for specific
    floating point instructions.
  - FEAT_RPRES: Increased precision of Reciprocal Estimate and
    Reciprocal Square Root Estimate from an 8-bit mantissa to a
    12-bit mantissa.

These features can be enabled by userspace by setting some new bits
in FPCR. These new bits are FPCR.{NEP, AH, FIZ}. Since these must be
explicitly enabled by userspace, this should not affect existing
applications.

This has been tested with:
  - FVP: combinations of both features, including mismatched CPUs
  - qemu: regression test, neither feature is supported
  - juno: regression test, neither feature is supported

Changes since v1 [1]:
  - Switch WFxT supported bit to the new value in ID_AA64ISAR2_EL1

Thanks,
Joey

Joey Gouly (3):
  arm64: cpufeature: add HWCAP for FEAT_AFP
  arm64: add ID_AA64ISAR2_EL1 sys register
  arm64: cpufeature: add HWCAP for FEAT_RPRES

 Documentation/arm64/cpu-feature-registers.rst | 17 +++++++++++++++++
 Documentation/arm64/elf_hwcaps.rst            |  8 ++++++++
 arch/arm64/include/asm/cpu.h                  |  1 +
 arch/arm64/include/asm/hwcap.h                |  2 ++
 arch/arm64/include/asm/sysreg.h               | 11 +++++++++++
 arch/arm64/include/uapi/asm/hwcap.h           |  2 ++
 arch/arm64/kernel/cpufeature.c                | 13 +++++++++++++
 arch/arm64/kernel/cpuinfo.c                   |  3 +++
 arch/arm64/kvm/sys_regs.c                     |  2 +-
 9 files changed, 58 insertions(+), 1 deletion(-)

-- 
2.17.1




More information about the linux-arm-kernel mailing list