All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Laveesh Bansal <laveeshb@laveeshbansal.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
	"Jason A. Donenfeld" <Jason@zx2c4.com>,
	Ard Biesheuvel <ardb@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] crypto: chacha - Consolidate XChaCha initialization
Date: Thu, 3 Dec 2026 22:34:26 -0800	[thread overview]
Message-ID: <20261204063426.GA2137@sol> (raw)
In-Reply-To: <20261204014328.89592-1-laveeshb@laveeshbansal.com>

On Thu, Dec 03, 2026 at 05:43:28PM -0800, Laveesh Bansal wrote:
> XChaCha initialization is repeated in three places. Each one derives a
> subkey with HChaCha from the key and the first 16 bytes of the nonce,
> then builds the ChaCha state from that subkey and the last 8 bytes of
> the nonce.
> 
> Add xchacha_init() to <crypto/chacha.h> and use it in all three. No
> functional change.
> 
> Signed-off-by: Laveesh Bansal <laveeshb@laveeshbansal.com>

Reviewed-by: Eric Biggers <ebiggers@kernel.org>

- Eric

      reply	other threads:[~2026-12-04  6:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-04  1:43 [PATCH v2] crypto: chacha - Consolidate XChaCha initialization Laveesh Bansal
2026-12-04  6:34 ` Eric Biggers [this message]

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=20261204063426.GA2137@sol \
    --to=ebiggers@kernel.org \
    --cc=Jason@zx2c4.com \
    --cc=ardb@kernel.org \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=laveeshb@laveeshbansal.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /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 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.