crypto: hash - Fix handling of sg entry that crosses page boundary
Herbert Xu authored
A quirk that we've always supported is having an sg entry that's
bigger than a page, or more generally an sg entry that crosses
page boundaries.  Even though it would be better to explicitly have
to sg entries for this, we need to support it for the existing users,
in particular, IPsec.

The new ahash sg walking code did try to handle this, but there was
a bug where we didn't increment the page so kept on walking on the
first page over an dover again.

This patch fixes it.
Tested-by: default avatarMartin Willi <martin@strongswan.org>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
d315a0e0
Name Last commit Last update
..
async_tx dmaengine: allow dma support for async_tx to be toggled
Kconfig crypto: testmgr - add zlib test
Makefile crypto: zlib - New zlib crypto module, using pcomp
ablkcipher.c crypto: skcipher - Avoid infinite loop when cipher fails selftest
aead.c crypto: aead - Avoid infinite loop when nivaead fails selftest
aes_generic.c crypto: aes - Precompute tables
ahash.c crypto: hash - Fix handling of sg entry that crosses page boundary
algapi.c crypto: api - Fix algorithm test race that broke aead initialisation
algboss.c crypto: testmgr - Test skciphers with no IVs
ansi_cprng.c crypto: ansi_cprng - Panic on CPRNG test failure when in FIPS mode
anubis.c [CRYPTO] all: Clean up init()/fini()
api.c crypto: api - Fix algorithm module auto-loading
arc4.c [CRYPTO] api: Get rid of flags argument to setkey
authenc.c crypto: authenc - Fix zero-length IV crash
blkcipher.c crypto: skcipher - Avoid infinite loop when cipher fails selftest
blowfish.c [CRYPTO] all: Clean up init()/fini()
camellia.c crypto: camellia - use kernel-provided bitops, unaligned access
cast5.c [CRYPTO] all: Clean up init()/fini()
cast6.c [CRYPTO] all: Clean up init()/fini()
cbc.c Convert ERR_PTR(PTR_ERR(p)) instances to ERR_CAST(p)
ccm.c crypto: ccm - Fix handling of null assoc data
chainiv.c crypto: chainiv - Use kcrypto_wq instead of keventd_wq
cipher.c [CRYPTO] api: Add missing headers for setkey_unaligned
compress.c cleanup asm/scatterlist.h includes
crc32c.c libcrc32c: Move implementation to crypto crc32c
cryptd.c
crypto_null.c
crypto_wq.c
ctr.c
cts.c
deflate.c
des_generic.c
digest.c
ecb.c
eseqiv.c
fcrypt.c
fips.c
gcm.c
gf128mul.c
hash.c
hmac.c
internal.h
khazad.c
krng.c
lrw.c
lzo.c
md4.c
md5.c
michael_mic.c
pcbc.c
pcompress.c
proc.c
ripemd.h
rmd128.c
rmd160.c
rmd256.c
rmd320.c
rng.c
salsa20_generic.c
scatterwalk.c
seed.c
seqiv.c
serpent.c
sha1_generic.c
sha256_generic.c
sha512_generic.c
shash.c
tcrypt.c
tcrypt.h
tea.c
testmgr.c
testmgr.h
tgr192.c
twofish.c
twofish_common.c
wp512.c
xcbc.c
xor.c
xts.c
zlib.c