]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: chacha20poly1305 - a few cleanups
authorEric Biggers <ebiggers@google.com>
Mon, 3 Jun 2019 05:46:34 +0000 (22:46 -0700)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 13 Jun 2019 06:31:40 +0000 (14:31 +0800)
commita8a679608cd78cc46a856b4c94c35bc69a3d62b2
treefa49ad9a1ffc55c43d86459fd89f1779f1615793
parent7eb9c933ea06d7aebf4df98720edd640b6a5cd33
crypto: chacha20poly1305 - a few cleanups

- Use sg_init_one() instead of sg_init_table() then sg_set_buf().

- Remove unneeded calls to sg_init_table() prior to scatterwalk_ffwd().

- Simplify initializing the poly tail block.

- Simplify computing padlen.

This doesn't change any actual behavior.

Cc: Martin Willi <martin@strongswan.org>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/chacha20poly1305.c