crypto: atmel-sha - fix sg list management
authorLeilei Zhao <leilei.zhao@atmel.com>
Tue, 7 Apr 2015 09:45:05 +0000 (17:45 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 8 Apr 2015 14:20:02 +0000 (22:20 +0800)
commit803eeae8f3eb394d898a7aa65ba706628dd6a85c
tree52e3a4f22974040a558543f2a13c0f71b3273c63
parent0099286b664493c85f0f2248f09f3b467a0e3a78
crypto: atmel-sha - fix sg list management

Having a zero length sg doesn't mean it is the end of the sg list. This
case happens when calculating HMAC of IPSec packet.

Signed-off-by: Leilei Zhao <leilei.zhao@atmel.com>
Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/atmel-sha.c