Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1# SPDX-License-Identifier: GPL-2.0-or-later
2
3config CRYPTO_LIB_POLY1305_KUNIT_TEST
4 tristate "KUnit tests for Poly1305" if !KUNIT_ALL_TESTS
5 depends on KUNIT
6 default KUNIT_ALL_TESTS || CRYPTO_SELFTESTS
7 select CRYPTO_LIB_BENCHMARK_VISIBLE
8 select CRYPTO_LIB_POLY1305
9 help
10 KUnit tests for the Poly1305 library functions.
11
12config CRYPTO_LIB_SHA1_KUNIT_TEST
13 tristate "KUnit tests for SHA-1" if !KUNIT_ALL_TESTS
14 depends on KUNIT
15 default KUNIT_ALL_TESTS || CRYPTO_SELFTESTS
16 select CRYPTO_LIB_BENCHMARK_VISIBLE
17 select CRYPTO_LIB_SHA1
18 help
19 KUnit tests for the SHA-1 cryptographic hash function and its
20 corresponding HMAC.
21
22# Option is named *_SHA256_KUNIT_TEST, though both SHA-224 and SHA-256 tests are
23# included, for consistency with the naming used elsewhere (e.g. CRYPTO_SHA256).
24config CRYPTO_LIB_SHA256_KUNIT_TEST
25 tristate "KUnit tests for SHA-224 and SHA-256" if !KUNIT_ALL_TESTS
26 depends on KUNIT
27 default KUNIT_ALL_TESTS || CRYPTO_SELFTESTS
28 select CRYPTO_LIB_BENCHMARK_VISIBLE
29 select CRYPTO_LIB_SHA256
30 help
31 KUnit tests for the SHA-224 and SHA-256 cryptographic hash functions
32 and their corresponding HMACs.
33
34# Option is named *_SHA512_KUNIT_TEST, though both SHA-384 and SHA-512 tests are
35# included, for consistency with the naming used elsewhere (e.g. CRYPTO_SHA512).
36config CRYPTO_LIB_SHA512_KUNIT_TEST
37 tristate "KUnit tests for SHA-384 and SHA-512" if !KUNIT_ALL_TESTS
38 depends on KUNIT
39 default KUNIT_ALL_TESTS || CRYPTO_SELFTESTS
40 select CRYPTO_LIB_BENCHMARK_VISIBLE
41 select CRYPTO_LIB_SHA512
42 help
43 KUnit tests for the SHA-384 and SHA-512 cryptographic hash functions
44 and their corresponding HMACs.
45
46config CRYPTO_LIB_BENCHMARK_VISIBLE
47 bool
48
49config CRYPTO_LIB_BENCHMARK
50 bool "Include benchmarks in KUnit tests for cryptographic functions"
51 depends on CRYPTO_LIB_BENCHMARK_VISIBLE
52 help
53 Include benchmarks in the KUnit tests for cryptographic functions.
54 The benchmark results are printed to the kernel log when the
55 corresponding KUnit test suite runs.
56
57 This is useful for evaluating the performance of the cryptographic
58 functions. However, it will increase the runtime of the KUnit tests.
59
60 If you're only interested in correctness testing, leave this disabled.