projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
eb27c76
)
kselftest/arm64: add crc32 feature to hwcap test
author
Zeng Heng
<zengheng4@huawei.com>
Tue, 8 Aug 2023 13:40:33 +0000
(21:40 +0800)
committer
Will Deacon
<will@kernel.org>
Fri, 11 Aug 2023 11:24:16 +0000
(12:24 +0100)
Add the CRC32 feature check in the set of hwcap tests.
Signed-off-by: Zeng Heng <zengheng4@huawei.com>
Reviewed-by: Mark Brown <broonie@kernel.org>
Link:
https://lore.kernel.org/r/20230808134036.668954-3-zengheng4@huawei.com
Signed-off-by: Will Deacon <will@kernel.org>
tools/testing/selftests/arm64/abi/hwcap.c
patch
|
blob
|
history
diff --git
a/tools/testing/selftests/arm64/abi/hwcap.c
b/tools/testing/selftests/arm64/abi/hwcap.c
index ec247587f2bf7593097d1368c72c603f42261994..70850bdb0e3540db9e7cd746f97aa8624b50cf50 100644
(file)
--- a/
tools/testing/selftests/arm64/abi/hwcap.c
+++ b/
tools/testing/selftests/arm64/abi/hwcap.c
@@
-33,6
+33,11
@@
*/
typedef void (*sigill_fn)(void);
+static void crc32_sigill(void)
+{
+ asm volatile("crc32w w0, w0, w1");
+}
+
static void cssc_sigill(void)
{
/* CNT x0, x0 */
@@
-233,6
+238,13
@@
static const struct hwcap_data {
sigill_fn sigill_fn;
bool sigill_reliable;
} hwcaps[] = {
+ {
+ .name = "CRC32",
+ .at_hwcap = AT_HWCAP,
+ .hwcap_bit = HWCAP_CRC32,
+ .cpuinfo = "crc32",
+ .sigill_fn = crc32_sigill,
+ },
{
.name = "CSSC",
.at_hwcap = AT_HWCAP2,