From: Ard Biesheuvel <ardb@kernel.org> To: Eric Biggers <ebiggers@kernel.org> Cc: Linux Crypto Mailing List <linux-crypto@vger.kernel.org>, Linux ARM <linux-arm-kernel@lists.infradead.org>, Herbert Xu <herbert@gondor.apana.org.au>, David Sterba <dsterba@suse.com>, "Jason A . Donenfeld" <Jason@zx2c4.com>, Paul Crowley <paulcrowley@google.com> Subject: Re: [PATCH v2 00/11] crypto: arm32-optimized BLAKE2b and BLAKE2s Date: Fri, 18 Dec 2020 17:30:39 +0100 [thread overview] Message-ID: <CAMj1kXEa5YaxdvgkYQEqOP8hpAs7mJsUhKoEpDHo7BRYKuqEkw@mail.gmail.com> (raw) In-Reply-To: <20201217222138.170526-1-ebiggers@kernel.org> On Thu, 17 Dec 2020 at 23:24, Eric Biggers <ebiggers@kernel.org> wrote: > > This patchset adds 32-bit ARM assembly language implementations of > BLAKE2b and BLAKE2s. > > The BLAKE2b implementation is NEON-accelerated, while the BLAKE2s > implementation uses scalar instructions since NEON doesn't work very > well for it. The BLAKE2b implementation is faster and is expected to be > useful as a replacement for SHA-1 in dm-verity, while the BLAKE2s > implementation would be useful for WireGuard which uses BLAKE2s. > > Both implementations are provided via the shash API, while BLAKE2s is > also provided via the library API. > > While adding these, I also reworked the generic implementations of > BLAKE2b and BLAKE2s to provide helper functions that make implementing > other "shash" providers for these algorithms much easier. > > See the individual commits for full details, including benchmarks. > > This patchset was tested on a Raspberry Pi 2 (which uses a Cortex-A7 > processor) with CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y, plus other tests. > > This patchset applies to mainline commit 0c6c887835b5. > > Changed since v1: > - Added BLAKE2s implementation. > - Adjusted the BLAKE2b helper functions to be consistent with what I > decided to do for BLAKE2s. > - Fixed build error in blake2b-neon-core.S in some configurations. > > Eric Biggers (11): > crypto: blake2b - rename constants for consistency with blake2s > crypto: blake2b - define shash_alg structs using macros > crypto: blake2b - export helpers for optimized implementations > crypto: blake2b - update file comment > crypto: arm/blake2b - add NEON-accelerated BLAKE2b > crypto: blake2s - define shash_alg structs using macros > crypto: x86/blake2s - define shash_alg structs using macros > crypto: blake2s - remove unneeded includes > crypto: blake2s - share the "shash" API boilerplate code > crypto: arm/blake2s - add ARM scalar optimized BLAKE2s > wireguard: Kconfig: select CRYPTO_BLAKE2S_ARM > Very nice! For the series, Acked-by: Ard Biesheuvel <ardb@kernel.org> > arch/arm/crypto/Kconfig | 20 ++ > arch/arm/crypto/Makefile | 4 + > arch/arm/crypto/blake2b-neon-core.S | 345 ++++++++++++++++++++++++++++ > arch/arm/crypto/blake2b-neon-glue.c | 105 +++++++++ > arch/arm/crypto/blake2s-core.S | 272 ++++++++++++++++++++++ > arch/arm/crypto/blake2s-glue.c | 78 +++++++ > arch/x86/crypto/blake2s-glue.c | 150 +++--------- > crypto/Kconfig | 5 + > crypto/Makefile | 1 + > crypto/blake2b_generic.c | 200 +++++++--------- > crypto/blake2s_generic.c | 161 +++---------- > crypto/blake2s_helpers.c | 87 +++++++ > drivers/net/Kconfig | 1 + > include/crypto/blake2b.h | 27 +++ > include/crypto/internal/blake2b.h | 33 +++ > include/crypto/internal/blake2s.h | 17 ++ > 16 files changed, 1139 insertions(+), 367 deletions(-) > create mode 100644 arch/arm/crypto/blake2b-neon-core.S > create mode 100644 arch/arm/crypto/blake2b-neon-glue.c > create mode 100644 arch/arm/crypto/blake2s-core.S > create mode 100644 arch/arm/crypto/blake2s-glue.c > create mode 100644 crypto/blake2s_helpers.c > create mode 100644 include/crypto/blake2b.h > create mode 100644 include/crypto/internal/blake2b.h > > > base-commit: 0c6c887835b59c10602add88057c9c06f265effe > -- > 2.29.2 >
WARNING: multiple messages have this Message-ID (diff)
From: Ard Biesheuvel <ardb@kernel.org> To: Eric Biggers <ebiggers@kernel.org> Cc: "Jason A . Donenfeld" <Jason@zx2c4.com>, Herbert Xu <herbert@gondor.apana.org.au>, Linux Crypto Mailing List <linux-crypto@vger.kernel.org>, David Sterba <dsterba@suse.com>, Linux ARM <linux-arm-kernel@lists.infradead.org>, Paul Crowley <paulcrowley@google.com> Subject: Re: [PATCH v2 00/11] crypto: arm32-optimized BLAKE2b and BLAKE2s Date: Fri, 18 Dec 2020 17:30:39 +0100 [thread overview] Message-ID: <CAMj1kXEa5YaxdvgkYQEqOP8hpAs7mJsUhKoEpDHo7BRYKuqEkw@mail.gmail.com> (raw) In-Reply-To: <20201217222138.170526-1-ebiggers@kernel.org> On Thu, 17 Dec 2020 at 23:24, Eric Biggers <ebiggers@kernel.org> wrote: > > This patchset adds 32-bit ARM assembly language implementations of > BLAKE2b and BLAKE2s. > > The BLAKE2b implementation is NEON-accelerated, while the BLAKE2s > implementation uses scalar instructions since NEON doesn't work very > well for it. The BLAKE2b implementation is faster and is expected to be > useful as a replacement for SHA-1 in dm-verity, while the BLAKE2s > implementation would be useful for WireGuard which uses BLAKE2s. > > Both implementations are provided via the shash API, while BLAKE2s is > also provided via the library API. > > While adding these, I also reworked the generic implementations of > BLAKE2b and BLAKE2s to provide helper functions that make implementing > other "shash" providers for these algorithms much easier. > > See the individual commits for full details, including benchmarks. > > This patchset was tested on a Raspberry Pi 2 (which uses a Cortex-A7 > processor) with CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y, plus other tests. > > This patchset applies to mainline commit 0c6c887835b5. > > Changed since v1: > - Added BLAKE2s implementation. > - Adjusted the BLAKE2b helper functions to be consistent with what I > decided to do for BLAKE2s. > - Fixed build error in blake2b-neon-core.S in some configurations. > > Eric Biggers (11): > crypto: blake2b - rename constants for consistency with blake2s > crypto: blake2b - define shash_alg structs using macros > crypto: blake2b - export helpers for optimized implementations > crypto: blake2b - update file comment > crypto: arm/blake2b - add NEON-accelerated BLAKE2b > crypto: blake2s - define shash_alg structs using macros > crypto: x86/blake2s - define shash_alg structs using macros > crypto: blake2s - remove unneeded includes > crypto: blake2s - share the "shash" API boilerplate code > crypto: arm/blake2s - add ARM scalar optimized BLAKE2s > wireguard: Kconfig: select CRYPTO_BLAKE2S_ARM > Very nice! For the series, Acked-by: Ard Biesheuvel <ardb@kernel.org> > arch/arm/crypto/Kconfig | 20 ++ > arch/arm/crypto/Makefile | 4 + > arch/arm/crypto/blake2b-neon-core.S | 345 ++++++++++++++++++++++++++++ > arch/arm/crypto/blake2b-neon-glue.c | 105 +++++++++ > arch/arm/crypto/blake2s-core.S | 272 ++++++++++++++++++++++ > arch/arm/crypto/blake2s-glue.c | 78 +++++++ > arch/x86/crypto/blake2s-glue.c | 150 +++--------- > crypto/Kconfig | 5 + > crypto/Makefile | 1 + > crypto/blake2b_generic.c | 200 +++++++--------- > crypto/blake2s_generic.c | 161 +++---------- > crypto/blake2s_helpers.c | 87 +++++++ > drivers/net/Kconfig | 1 + > include/crypto/blake2b.h | 27 +++ > include/crypto/internal/blake2b.h | 33 +++ > include/crypto/internal/blake2s.h | 17 ++ > 16 files changed, 1139 insertions(+), 367 deletions(-) > create mode 100644 arch/arm/crypto/blake2b-neon-core.S > create mode 100644 arch/arm/crypto/blake2b-neon-glue.c > create mode 100644 arch/arm/crypto/blake2s-core.S > create mode 100644 arch/arm/crypto/blake2s-glue.c > create mode 100644 crypto/blake2s_helpers.c > create mode 100644 include/crypto/blake2b.h > create mode 100644 include/crypto/internal/blake2b.h > > > base-commit: 0c6c887835b59c10602add88057c9c06f265effe > -- > 2.29.2 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-12-18 16:31 UTC|newest] Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-12-17 22:21 [PATCH v2 00/11] crypto: arm32-optimized BLAKE2b and BLAKE2s Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 01/11] crypto: blake2b - rename constants for consistency with blake2s Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 02/11] crypto: blake2b - define shash_alg structs using macros Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 03/11] crypto: blake2b - export helpers for optimized implementations Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 04/11] crypto: blake2b - update file comment Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 05/11] crypto: arm/blake2b - add NEON-accelerated BLAKE2b Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 06/11] crypto: blake2s - define shash_alg structs using macros Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 07/11] crypto: x86/blake2s " Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 08/11] crypto: blake2s - remove unneeded includes Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 09/11] crypto: blake2s - share the "shash" API boilerplate code Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-18 16:14 ` Jason A. Donenfeld 2020-12-18 16:14 ` Jason A. Donenfeld 2020-12-18 20:08 ` Eric Biggers 2020-12-18 20:08 ` Eric Biggers 2020-12-19 0:01 ` Jason A. Donenfeld 2020-12-19 0:01 ` Jason A. Donenfeld 2020-12-22 8:55 ` Eric Biggers 2020-12-22 8:55 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 10/11] crypto: arm/blake2s - add ARM scalar optimized BLAKE2s Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-17 22:21 ` [PATCH v2 11/11] wireguard: Kconfig: select CRYPTO_BLAKE2S_ARM Eric Biggers 2020-12-17 22:21 ` Eric Biggers 2020-12-18 16:02 ` Jason A. Donenfeld 2020-12-18 16:02 ` Jason A. Donenfeld 2020-12-18 16:30 ` Ard Biesheuvel [this message] 2020-12-18 16:30 ` [PATCH v2 00/11] crypto: arm32-optimized BLAKE2b and BLAKE2s Ard Biesheuvel
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=CAMj1kXEa5YaxdvgkYQEqOP8hpAs7mJsUhKoEpDHo7BRYKuqEkw@mail.gmail.com \ --to=ardb@kernel.org \ --cc=Jason@zx2c4.com \ --cc=dsterba@suse.com \ --cc=ebiggers@kernel.org \ --cc=herbert@gondor.apana.org.au \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-crypto@vger.kernel.org \ --cc=paulcrowley@google.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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.