crypto: omap-crypto - copy the temporary data to output buffer properly
authorTero Kristo <t-kristo@ti.com>
Tue, 5 Nov 2019 14:01:11 +0000 (16:01 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 11 Dec 2019 08:37:00 +0000 (16:37 +0800)
commit839bb2a9ca73a99e1df882d14fe8060761373376
tree5b86fcabe275a6b89d203014ae06cea0b5c3fc7c
parentaca8bf0027d3ab4492d47e6b05b13911948903db
crypto: omap-crypto - copy the temporary data to output buffer properly

Both source and destination are scatterlists that can contain multiple
entries under the omap crypto cleanup handling. Current code only copies
data from the first source scatterlist entry to the target scatterlist,
potentially omitting any sg entries following the first one. Instead,
implement a new routine that walks through both source and target and
copies the data over once it goes.

Signed-off-by: Tero Kristo <t-kristo@ti.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/omap-crypto.c