crypto: atmel-aes - Fix CTR counter overflow when multiple fragments
authorTudor Ambarus <tudor.ambarus@microchip.com>
Fri, 13 Dec 2019 14:45:44 +0000 (14:45 +0000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 20 Dec 2019 06:58:35 +0000 (14:58 +0800)
commit3907ccfaec5d9965e306729936fc732c94d2c1e7
treeb45849ca6f26bc80bbfdaee058dfb5ee8050a308
parent27896aff15d66c241a87402bea81dc03c9fb80bd
crypto: atmel-aes - Fix CTR counter overflow when multiple fragments

The CTR transfer works in fragments of data of maximum 1 MByte because
of the 16 bit CTR counter embedded in the IP. Fix the CTR counter
overflow handling for messages larger than 1 MByte.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Fixes: 781a08d9740a ("crypto: atmel-aes - Fix counter overflow in CTR mode")
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/atmel-aes.c