crypto: marvell - Check engine is not already running when enabling a req
authorRomain Perier <romain.perier@free-electrons.com>
Tue, 21 Jun 2016 08:08:32 +0000 (10:08 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 23 Jun 2016 10:14:00 +0000 (18:14 +0800)
commitf62830886f6b8cb2f1c55e23cb5eab51c4b9ef2c
tree0bac261d8f9d3e60f43ad678c13d15b67002ef1e
parente26df73f80290efe5c772d94ac3a3cf2b077fe5b
crypto: marvell - Check engine is not already running when enabling a req

Add a BUG_ON() call when the driver tries to launch a crypto request
while the engine is still processing the previous one. This replaces
a silent system hang by a verbose kernel panic with the associated
backtrace to let the user know that something went wrong in the CESA
driver.

Signed-off-by: Romain Perier <romain.perier@free-electrons.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/marvell/cipher.c
drivers/crypto/marvell/hash.c
drivers/crypto/marvell/tdma.c