]> git.ipfire.org Git - thirdparty/linux.git/commit
crypto: talitos - fix SEC1 32k ahash request limitation
authorPaul Louvel <paul.louvel@bootlin.com>
Mon, 30 Mar 2026 10:28:18 +0000 (12:28 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Sun, 12 Apr 2026 08:46:29 +0000 (16:46 +0800)
commit655ef638a2bc3cd0a9eff99a02f83cab94a3a917
tree9be39edf1738848f6fa6821e7254f1c4144ee90e
parent01d798e9feb30212952d4e992801ba6bd6a82351
crypto: talitos - fix SEC1 32k ahash request limitation

Since commit c662b043cdca ("crypto: af_alg/hash: Support
MSG_SPLICE_PAGES"), the crypto core may pass large scatterlists spanning
multiple pages to drivers supporting ahash operations. As a result, a
driver can now receive large ahash requests.

The SEC1 engine has a limitation where a single descriptor cannot
process more than 32k of data. The current implementation attempts to
handle the entire request within a single descriptor, which leads to
failures raised by the driver:

  "length exceeds h/w max limit"

Address this limitation by splitting large ahash requests into multiple
descriptors, each respecting the 32k hardware limit. This allows
processing arbitrarily large requests.

Cc: stable@vger.kernel.org
Fixes: c662b043cdca ("crypto: af_alg/hash: Support MSG_SPLICE_PAGES")
Signed-off-by: Paul Louvel <paul.louvel@bootlin.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/talitos.c