]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
crypto: marvell - Fix memory leaks in TDMA chain for cipher requests
authorRomain Perier <romain.perier@free-electrons.com>
Fri, 22 Jul 2016 12:40:39 +0000 (14:40 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 28 Jul 2016 05:04:42 +0000 (13:04 +0800)
commitec38f82e85532bdde27af8dea8e6c09e26f88e16
tree165ec23b29c0f2a06adb6aadd9042e6c8a11c87d
parentbbce2ad2d711c12d93145a7bbdf086e73f414bcd
crypto: marvell - Fix memory leaks in TDMA chain for cipher requests

So far in mv_cesa_ablkcipher_dma_req_init, if an error is thrown while
the tdma chain is built there is a memory leak. This issue exists
because the chain is assigned later at the end of the function, so the
cleanup function is called with the wrong version of the chain.

Fixes: db509a45339f ("crypto: marvell/cesa - add TDMA support")
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