kselftest/arm64: Add simple hwcap validation
PATCH v2 1/1 kselftest/arm64: Add simple hwcap validation
Add some trivial hwcap validation which checks that /proc/cpuinfo and AT_HWCAP agree with each other and can verify that for extensions that can generate a SIGILL due to adding new instructions one appears or doesn't appear as expected. I've added SVE and SME, other capabilities can be added later if this gets merged.
This isn't super exciting but on the other hand took very little time to write and should be handy when verifying that you wired up AT_HWCAP properly.
--- tools/testing/selftests/arm64/abi/.gitignore | 1 + tools/testing/selftests/arm64/abi/Makefile | 2 +- tools/testing/selftests/arm64/abi/hwcap.c | 188 +++++++++++++++++++ 3 files changed, 190 insertions(+), 1 deletion(-) create mode 100644 tools/testing/selftests/arm64/abi/hwcap.c
tools/testing/selftests/arm64/abi/.gitignore +1 -0
@@ -1,2 +1,3 @@ +hwcap syscall-abi tpidr2
tools/testing/selftests/arm64/abi/Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (C) 2021 ARM Limited -TEST_GEN_PROGS := syscall-abi tpidr2 +TEST_GEN_PROGS := hwcap syscall-abi tpidr2 include ../../lib.mk
tools/testing/selftests/arm64/abi/hwcap.c new file +188 -0
188 lines not on this page · raw message
base-commit: b90cb1053190353cc30f0fef0ef1f378ccc063c5
Signature · 1 line
2.30.2
Catalin Marinas
maintainerQuoted 11 lines · Mark Brown
Add some trivial hwcap validation which checks that
/proc/cpuinfoandAT_HWCAPagree with each other and can verify that for extensions that can generate a SIGILL due to adding new instructions one appears or doesn't appear as expected. I've added SVE and SME, other capabilities can be added later if this gets merged.This isn't super exciting but on the other hand took very little time to write and should be handy when verifying that you wired up
AT_HWCAPproperly.[...]
Applied to arm64 (for-next/kselftest), thanks!
[1/1] kselftest/arm64: Add simple hwcap validation
https://git.kernel.org/arm64/c/7a9bcaaad5f1
Signature · 1 line
Catalin