public inbox for linux-crypto@vger.kernel.org
 help / color / mirror / Atom feed
From: Robert Elliott <elliott@hpe.com>
To: herbert@gondor.apana.org.au, davem@davemloft.net,
	linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: toshi.kani@hpe.com, Robert Elliott <elliott@hpe.com>
Subject: [PATCH 7/8] crypto: Kconfig - sort the digests
Date: Mon, 15 Aug 2022 14:06:07 -0500	[thread overview]
Message-ID: <20220815190608.47182-8-elliott@hpe.com> (raw)
In-Reply-To: <20220815190608.47182-1-elliott@hpe.com>

Sort the entries in Digests by their displayed names.
In particular, keep the optimized CPU implementations next to the
generic implementations.

Signed-off-by: Robert Elliott <elliott@hpe.com>
---
 crypto/Kconfig | 299 ++++++++++++++++++++++++-------------------------
 1 file changed, 149 insertions(+), 150 deletions(-)

diff --git a/crypto/Kconfig b/crypto/Kconfig
index 0116729ea369..f5cfb73e2423 100644
--- a/crypto/Kconfig
+++ b/crypto/Kconfig
@@ -632,6 +632,58 @@ menu "Hash modes"
 
 menu "Digests"
 
+config CRYPTO_BLAKE2B
+	tristate "BLAKE2b"
+	select CRYPTO_HASH
+	help
+	  BLAKE2b cryptographic hash function (RFC 7693)
+
+	  BLAKE2b is optimized for 64-bit platforms and can produce digests
+	  of any size between 1 and 64 bytes. The keyed hash is also implemented.
+
+	  This module provides the following algorithms:
+	  - blake2b-160
+	  - blake2b-256
+	  - blake2b-384
+	  - blake2b-512
+
+	  See https://blake2.net for further information.
+
+	  Used by the btrfs filesystem.
+
+config CRYPTO_BLAKE2S
+	tristate "BLAKE2s"
+	select CRYPTO_LIB_BLAKE2S_GENERIC
+	select CRYPTO_HASH
+	help
+	  BLAKE2s cryptographic hash function (RFC 7693)
+
+	  BLAKE2s is optimized for 8 to 32-bit platforms and can produce
+	  digests of any size between 1 and 32 bytes. The keyed hash is
+	  also implemented.
+
+	  This module provides the following algorithms:
+	  - blake2s-128
+	  - blake2s-160
+	  - blake2s-224
+	  - blake2s-256
+
+	  Used by Wireguard.
+
+	  See https://blake2.net for further information.
+
+config CRYPTO_BLAKE2S_X86
+	tristate "BLAKE2s (x86_64 with SSSE3/AVX-512)"
+	depends on X86 && 64BIT
+	select CRYPTO_LIB_BLAKE2S_GENERIC
+	select CRYPTO_ARCH_HAVE_LIB_BLAKE2S
+	help
+	  BLAKE2s cryptographic hash function (RFC 7693)
+
+	  Architecture: x86_64 using:
+	  * SSSE3 (Supplemental SSE3)
+	  * AVX-512 (Advanced Vector Extensions-512)
+
 config CRYPTO_CRC32C
 	tristate "CRC32c"
 	select CRYPTO_HASH
@@ -726,69 +778,6 @@ menu "Digests"
 
 	  It is available with IBM z13 or later.
 
-config CRYPTO_XXHASH
-	tristate "xxHash"
-	select CRYPTO_HASH
-	select XXHASH
-	help
-	  xxHash non-cryptographic hash algorithm
-
-	  Extremely fast, working at speeds close to RAM limits.
-
-	  Used by the btrfs filesystem.
-
-config CRYPTO_BLAKE2B
-	tristate "BLAKE2b"
-	select CRYPTO_HASH
-	help
-	  BLAKE2b cryptographic hash function (RFC 7693)
-
-	  BLAKE2b is optimized for 64-bit platforms and can produce digests
-	  of any size between 1 and 64 bytes. The keyed hash is also implemented.
-
-	  This module provides the following algorithms:
-	  - blake2b-160
-	  - blake2b-256
-	  - blake2b-384
-	  - blake2b-512
-
-	  See https://blake2.net for further information.
-
-	  Used by the btrfs filesystem.
-
-config CRYPTO_BLAKE2S
-	tristate "BLAKE2s"
-	select CRYPTO_LIB_BLAKE2S_GENERIC
-	select CRYPTO_HASH
-	help
-	  BLAKE2s cryptographic hash function (RFC 7693)
-
-	  BLAKE2s is optimized for 8 to 32-bit platforms and can produce
-	  digests of any size between 1 and 32 bytes. The keyed hash is
-	  also implemented.
-
-	  This module provides the following algorithms:
-	  - blake2s-128
-	  - blake2s-160
-	  - blake2s-224
-	  - blake2s-256
-
-	  Used by Wireguard.
-
-	  See https://blake2.net for further information.
-
-config CRYPTO_BLAKE2S_X86
-	tristate "BLAKE2s (x86_64 with SSSE3/AVX-512)"
-	depends on X86 && 64BIT
-	select CRYPTO_LIB_BLAKE2S_GENERIC
-	select CRYPTO_ARCH_HAVE_LIB_BLAKE2S
-	help
-	  BLAKE2s cryptographic hash function (RFC 7693)
-
-	  Architecture: x86_64 using:
-	  * SSSE3 (Supplemental SSE3)
-	  * AVX-512 (Advanced Vector Extensions-512)
-
 config CRYPTO_CRCT10DIF
 	tristate "CRCT10DIF"
 	select CRYPTO_HASH
@@ -819,6 +808,14 @@ menu "Digests"
 	  Architecture: powerpc64 using AltiVec extensions
 	  Enable on POWER8 and newer processors for improved performance.
 
+config CRYPTO_VPMSUM_TESTER
+	tristate "CRC32C and CRC32T10DIF vpmsum hardware acceleration tester (powerpc64)"
+	depends on CRYPTO_CRCT10DIF_VPMSUM && CRYPTO_CRC32C_VPMSUM
+	help
+	  Stress test for CRC32c and CRCT10DIF algorithms implemented with
+	  powerpc64 AltiVec extensions (POWER8 vpmsum instructions).
+	  Unless you are testing these algorithms, you don't need this.
+
 config CRYPTO_CRC64_ROCKSOFT
 	tristate "CRC64 based on the Rocksoft Model CRC Algorithm"
 	depends on CRC64
@@ -830,14 +827,6 @@ menu "Digests"
 
 	  See https://zlib.net/crc_v3.txt
 
-config CRYPTO_VPMSUM_TESTER
-	tristate "CRC32C and CRC32T10DIF vpmsum hardware acceleration tester (powerpc64)"
-	depends on CRYPTO_CRCT10DIF_VPMSUM && CRYPTO_CRC32C_VPMSUM
-	help
-	  Stress test for CRC32c and CRCT10DIF algorithms implemented with
-	  powerpc64 AltiVec extensions (POWER8 vpmsum instructions).
-	  Unless you are testing these algorithms, you don't need this.
-
 config CRYPTO_GHASH
 	tristate "GHASH"
 	select CRYPTO_GF128MUL
@@ -845,37 +834,26 @@ menu "Digests"
 	help
 	  GCM GHASH function (NIST SP800-38D)
 
-config CRYPTO_POLY1305
-	tristate "Poly1305"
-	select CRYPTO_HASH
-	select CRYPTO_LIB_POLY1305_GENERIC
-	help
-	  Poly1305 authenticator algorithm (RFC7539)
-
-	  Poly1305 is an authenticator algorithm designed by Daniel J. Bernstein.
-	  It is used for the ChaCha20-Poly1305 AEAD, specified in RFC7539 for use
-	  in IETF protocols. This is the portable C implementation of Poly1305.
-
-config CRYPTO_POLY1305_X86_64
-	tristate "Poly1305 (x86_64 with SSE2/AVX2)"
+config CRYPTO_GHASH_CLMUL_NI_INTEL
+	tristate "GHASH (x86_64 with CLMUL-NI)"
 	depends on X86 && 64BIT
-	select CRYPTO_LIB_POLY1305_GENERIC
-	select CRYPTO_ARCH_HAVE_LIB_POLY1305
+	select CRYPTO_CRYPTD
 	help
-	  Poly1305 authenticator algorithm (RFC7539)
+	  GCM GHASH hash function (NIST SP800-38D)
 
 	  Architecture: x86_64 using:
-	  * SSE2 (Streaming SIMD Extensions 2)
-	  * AVX2 (Advanced Vector Extensions 2)
+	  * CLMUL-NI (carry-less multiplication new instructions)
 
-config CRYPTO_POLY1305_MIPS
-	tristate "Poly1305 (MIPS)"
-	depends on MIPS
-	select CRYPTO_ARCH_HAVE_LIB_POLY1305
+config CRYPTO_GHASH_S390
+	tristate "GHASH (s390)"
+	depends on S390
+	select CRYPTO_HASH
 	help
-	  Poly1305 authenticator algorithm (RFC7539)
+	  GCM GHASH hash function (NIST SP800-38D)
 
-	  Architecture: mips
+	  Architecture: s390
+
+	  It is available as of z196.
 
 config CRYPTO_MD4
 	tristate "MD4"
@@ -930,6 +908,38 @@ menu "Digests"
 	  This algorithm is required for TKIP, but it should not be used for
 	  other purposes because of the weakness of the algorithm.
 
+config CRYPTO_POLY1305
+	tristate "Poly1305"
+	select CRYPTO_HASH
+	select CRYPTO_LIB_POLY1305_GENERIC
+	help
+	  Poly1305 authenticator algorithm (RFC7539)
+
+	  Poly1305 is an authenticator algorithm designed by Daniel J. Bernstein.
+	  It is used for the ChaCha20-Poly1305 AEAD, specified in RFC7539 for use
+	  in IETF protocols. This is the portable C implementation of Poly1305.
+
+config CRYPTO_POLY1305_X86_64
+	tristate "Poly1305 (x86_64 with SSE2/AVX2)"
+	depends on X86 && 64BIT
+	select CRYPTO_LIB_POLY1305_GENERIC
+	select CRYPTO_ARCH_HAVE_LIB_POLY1305
+	help
+	  Poly1305 authenticator algorithm
+
+	  Architecture: x86_64 using:
+	  * SSE2 (Streaming SIMD Extensions 2)
+	  * AVX2 (Advanced Vector Extensions 2)
+
+config CRYPTO_POLY1305_MIPS
+	tristate "Poly1305 (MIPS)"
+	depends on MIPS
+	select CRYPTO_ARCH_HAVE_LIB_POLY1305
+	help
+	  Poly1305 authenticator algorithm
+
+	  Architecture: mips
+
 config CRYPTO_RMD160
 	tristate "RIPEMD-160"
 	select CRYPTO_HASH
@@ -968,44 +978,6 @@ menu "Digests"
 	  * AVX2 (Advanced Vector Extensions 2)
 	  * SHA-NI (SHA Extensions New Instructions)
 
-config CRYPTO_SHA256_SSSE3
-	tristate "SHA224 and SHA256 (x86_64 with SSSE3/AVX/AVX2/SHA-NI)"
-	depends on X86 && 64BIT
-	select CRYPTO_SHA256
-	select CRYPTO_HASH
-	help
-	  SHA-224 and SHA-256 secure hash algorithms (FIPS 180)
-
-	  Architecture: x86_64 using:
-	  * SSSE3 (Supplemental SSE3)
-	  * AVX (Advanced Vector Extensions)
-	  * AVX2 (Advanced Vector Extensions 2)
-	  * SHA-NI (SHA Extensions New Instructions)
-
-config CRYPTO_SHA512_SSSE3
-	tristate "SHA384 and SHA512 (x86_64 with SSSE3/AVX/AVX2)"
-	depends on X86 && 64BIT
-	select CRYPTO_SHA512
-	select CRYPTO_HASH
-	help
-	  SHA-384 and SHA-512 secure hash algorithms (FIPS 180)
-
-	  Architecture: x86_64 using:
-	  * SSSE3 (Supplemental SSE3)
-	  * AVX (Advanced Vector Extensions)
-	  * AVX2 (Advanced Vector Extensions 2)
-
-config CRYPTO_SHA512_S390
-	tristate "SHA384 and SHA512 (s390)"
-	depends on S390
-	select CRYPTO_HASH
-	help
-	  SHA-384 and SHA-512 secure hash algorithms (FIPS 180)
-
-	  Architecture: s390
-
-	  It is available as of z10.
-
 config CRYPTO_SHA1_OCTEON
 	tristate "SHA1 (OCTEON)"
 	depends on CPU_CAVIUM_OCTEON
@@ -1063,6 +1035,20 @@ menu "Digests"
 	  This is required for IPsec AH (XFRM_AH) and IPsec ESP (XFRM_ESP).
 	  Used by the btrfs filesystem, Ceph, NFS, and SMB.
 
+config CRYPTO_SHA256_SSSE3
+	tristate "SHA224 and SHA256 (x86_64 with SSSE3/AVX/AVX2/SHA-NI)"
+	depends on X86 && 64BIT
+	select CRYPTO_SHA256
+	select CRYPTO_HASH
+	help
+	  SHA-224 and SHA-256 secure hash algorithms (FIPS 180)
+
+	  Architecture: x86_64 using:
+	  * SSSE3 (Supplemental SSE3)
+	  * AVX (Advanced Vector Extensions)
+	  * AVX2 (Advanced Vector Extensions 2)
+	  * SHA-NI (SHA Extensions New Instructions)
+
 config CRYPTO_SHA256_PPC_SPE
 	tristate "SHA224 and SHA256 (PPC SPE)"
 	depends on PPC && SPE
@@ -1110,6 +1096,30 @@ menu "Digests"
 	help
 	  SHA-384 and SHA-512 secure hash algorithms (FIPS 180)
 
+config CRYPTO_SHA512_SSSE3
+	tristate "SHA384 and SHA512 (x86_64 with SSSE3/AVX/AVX2)"
+	depends on X86 && 64BIT
+	select CRYPTO_SHA512
+	select CRYPTO_HASH
+	help
+	  SHA-384 and SHA-512 secure hash algorithms (FIPS 180)
+
+	  Architecture: x86_64 using:
+	  * SSSE3 (Supplemental SSE3)
+	  * AVX (Advanced Vector Extensions)
+	  * AVX2 (Advanced Vector Extensions 2)
+
+config CRYPTO_SHA512_S390
+	tristate "SHA384 and SHA512 (s390)"
+	depends on S390
+	select CRYPTO_HASH
+	help
+	  SHA-384 and SHA-512 secure hash algorithms (FIPS 180)
+
+	  Architecture: s390
+
+	  It is available as of z10.
+
 config CRYPTO_SHA512_OCTEON
 	tristate "SHA384 and SHA512 (OCTEON)"
 	depends on CPU_CAVIUM_OCTEON
@@ -1213,27 +1223,16 @@ menu "Digests"
 	  See https://web.archive.org/web/20171129084214/http://www.larc.usp.br/~pbarreto/WhirlpoolPage.html
 	  for further information.
 
-config CRYPTO_GHASH_CLMUL_NI_INTEL
-	tristate "GHASH (x86_64 with CLMUL-NI)"
-	depends on X86 && 64BIT
-	select CRYPTO_CRYPTD
-	help
-	  GCM GHASH hash function (NIST SP800-38D)
-
-	  Architecture: x86_64 using:
-	  * CLMUL-NI (carry-less multiplication new instructions)
-
-config CRYPTO_GHASH_S390
-	tristate "GHASH (s390)"
-	depends on S390
+config CRYPTO_XXHASH
+	tristate "xxHash"
 	select CRYPTO_HASH
+	select XXHASH
 	help
-	  GCM GHASH hash function (NIST SP800-38D)
-
-	  Architecture: s390
+	  xxHash non-cryptographic hash algorithm
 
-	  It is available as of z196.
+	  Extremely fast, working at speeds close to RAM limits.
 
+	  Used by the btrfs filesystem.
 endmenu
 
 menu "Ciphers"
-- 
2.37.1


  parent reply	other threads:[~2022-08-15 20:37 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-15 19:06 [PATCH 0/8] crypto: Kconfig - simplify menus and help text Robert Elliott
2022-08-15 19:06 ` [PATCH 1/8] crypto: Kconfig - add submenus Robert Elliott
2022-08-15 19:06 ` [PATCH 2/8] crypto: Kconfig - simplify public-key entries Robert Elliott
2022-08-15 19:06 ` [PATCH 3/8] crypto: Kconfig - simplify user-space interface entries Robert Elliott
2022-08-15 19:06 ` [PATCH 4/8] crypto: Kconfig - simplify AEAD and block mode entries Robert Elliott
2022-08-15 19:06 ` [PATCH 5/8] crypto: Kconfig - simplify hash mode and digest entries Robert Elliott
2022-08-15 19:06 ` [PATCH 6/8] crypto: Kconfig - simplify cipher, compression, and RNG entries Robert Elliott
2022-08-15 19:06 ` Robert Elliott [this message]
2022-08-15 19:06 ` [PATCH 8/8] crypto: Kconfig - sort the ciphers Robert Elliott
2022-08-15 21:36   ` Eric Biggers
2022-08-16  3:13     ` Elliott, Robert (Servers)
2022-08-17 23:20   ` [PATCH v2 00/10] crypto: Kconfig - simplify menus and help text Robert Elliott
2022-08-17 23:20     ` [PATCH v2 01/10] crypto: Kconfig - move mips entries to a submenu Robert Elliott
2022-08-17 23:20     ` [PATCH v2 02/10] crypto: Kconfig - move powerpc " Robert Elliott
2022-08-17 23:20     ` [PATCH v2 03/10] crypto: Kconfig - move s390 " Robert Elliott
2022-08-17 23:20     ` [PATCH v2 04/10] crypto: Kconfig - move sparc " Robert Elliott
2022-08-17 23:20     ` [PATCH v2 05/10] crypto: Kconfig - move x86 " Robert Elliott
2022-08-17 23:20     ` [PATCH v2 06/10] crypto: Kconfig - remove AES_ARM64 selection by SA2UL entry Robert Elliott
2022-08-17 23:20     ` [PATCH v2 07/10] crypto: Kconfig - move arm and arm64 menus to Crypto API page Robert Elliott
2022-08-17 23:20     ` [PATCH v2 08/10] crypto: Kconfig - sort the arm64 entries Robert Elliott
2022-08-17 23:20     ` [PATCH v2 09/10] crypto: Kconfig - sort the arm entries Robert Elliott
2022-08-17 23:20     ` [PATCH v2 10/10] crypto: Kconfig - add submenus Robert Elliott
2022-08-18  4:43       ` Eric Biggers
2022-08-18  5:44         ` Elliott, Robert (Servers)
2022-08-18  0:42     ` [PATCH v2 00/10] crypto: Kconfig - simplify menus and help text Nayna
2022-08-18  2:13       ` Elliott, Robert (Servers)
2022-08-18  2:43         ` Elliott, Robert (Servers)
2022-08-18  2:47     ` Eric Biggers
2022-08-18  3:00       ` Elliott, Robert (Servers)
2022-08-18  4:28         ` Eric Biggers
2022-08-20 18:41     ` [PATCH v3 00/17] " Robert Elliott
2022-08-20 18:41       ` [PATCH v3 01/17] crypto: Kconfig - move mips entries to a submenu Robert Elliott
2022-08-20 18:41       ` [PATCH v3 02/17] crypto: Kconfig - move powerpc " Robert Elliott
2022-08-20 18:41       ` [PATCH v3 03/17] crypto: Kconfig - move s390 " Robert Elliott
2022-08-20 18:41       ` [PATCH v3 04/17] crypto: Kconfig - move sparc " Robert Elliott
2022-08-20 18:41       ` [PATCH v3 05/17] crypto: Kconfig - move x86 " Robert Elliott
2022-08-20 18:41       ` [PATCH v3 06/17] crypto: Kconfig - remove AES_ARM64 ref by SA2UL Robert Elliott
2022-08-20 18:41       ` [PATCH v3 07/17] crypto: Kconfig - submenus for arm and arm64 Robert Elliott
2022-08-20 18:41       ` [PATCH v3 08/17] crypto: Kconfig - sort the arm64 entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 09/17] crypto: Kconfig - sort the arm entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 10/17] crypto: Kconfig - add submenus Robert Elliott
2022-08-20 18:41       ` [PATCH v3 11/17] crypto: Kconfig - simplify public-key entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 12/17] crypto: Kconfig - simplify CRC entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 13/17] crypto: Kconfig - simplify aead entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 14/17] crypto: Kconfig - simplify hash entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 15/17] crypto: Kconfig - simplify userspace entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 16/17] crypto: Kconfig - simplify cipher entries Robert Elliott
2022-08-20 18:41       ` [PATCH v3 17/17] crypto: Kconfig - simplify compression/RNG entries Robert Elliott
2022-08-26 11:08       ` [PATCH v3 00/17] crypto: Kconfig - simplify menus and help text Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220815190608.47182-8-elliott@hpe.com \
    --to=elliott@hpe.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=toshi.kani@hpe.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox