linux_dsm_epyc7002/drivers/crypto/allwinner
Corentin Labbe 098a597f31 crypto: sun8i-ce - fix two error path's memory leak
[ Upstream commit 732b764099f651a088fd931d7b8121b6aa84e62e ]

This patch fixes the following smatch warnings:
drivers/crypto/allwinner/sun8i-ce/sun8i-ce-hash.c:412
sun8i_ce_hash_run() warn: possible memory leak of 'result'
Note: "buf" is leaked as well.

Furthermore, in case of ENOMEM, crypto_finalize_hash_request() was not
called which was an error.

Fixes: 56f6d5aee8 ("crypto: sun8i-ce - support hash algorithms")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-12-30 11:53:17 +01:00
..
sun4i-ss crypto: sun4i-ss - Fix sparse endianness markers 2020-09-18 17:20:10 +10:00
sun8i-ce crypto: sun8i-ce - fix two error path's memory leak 2020-12-30 11:53:17 +01:00
sun8i-ss crypto: sun8i-ss - fix comparison of integer expressions of different signedness 2020-09-25 17:48:51 +10:00
Kconfig crypto: sun8i-ce - Add support for the TRNG 2020-09-25 17:48:28 +10:00
Makefile crypto: allwinner - Add sun8i-ss cryptographic offloader 2019-11-01 13:38:31 +08:00