[HIFN]: Properly handle requests for less than the full scatterlist
authorPatrick McHardy <kaber@trash.net>
Wed, 7 May 2008 14:34:27 +0000 (22:34 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 10 Jul 2008 12:35:11 +0000 (20:35 +0800)
The scatterlist may contain more data than the crypto request, causing
an underflow of the remaining byte count while walking the list.

Use the minimum of the scatterlist element size and the remaining byte
count specified in the crypto request to avoid this.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Acked-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

No differences found