]> git.baikalelectronics.ru Git - arm-tf.git/commit
refactor(cpufeat): enable FEAT_RNG for FEAT_STATE_CHECKED
authorAndre Przywara <andre.przywara@arm.com>
Wed, 22 Feb 2023 17:55:59 +0000 (17:55 +0000)
committerAndre Przywara <andre.przywara@arm.com>
Wed, 22 Mar 2023 13:33:22 +0000 (13:33 +0000)
commitac17e52c728e7786e80f41e41673420433637fa6
tree1e24d7853f445d1a2fe7c74dae3692e7dda3f0b4
parent623f6140fc8eaa547d477179b67ca2fde2720fe4
refactor(cpufeat): enable FEAT_RNG for FEAT_STATE_CHECKED

At the moment we only support for FEAT_RNG to be either unconditionally
compiled in, or to be not supported at all.

Add support for runtime detection (FEAT_RNG=2), by splitting
is_armv8_5_rng_present() into an ID register reading function and a second
function to report the support status. That function considers both build
time settings and runtime information (if needed), and is used before we
access the RNDRRS system register.

Change the QEMU platform default to the now supported dynamic option (=2),
so the right decision can be made by the code at runtime.

Change-Id: I1a4a538d5ad395fead7324f297d0056bda4f84cb
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
common/feat_detect.c
include/arch/aarch64/arch_features.h
plat/qemu/common/qemu_stack_protector.c
plat/qemu/qemu/platform.mk