From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-bn3nam01on0113.outbound.protection.outlook.com ([104.47.33.113]:60480 "EHLO NAM01-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752064AbeA1W1u (ORCPT ); Sun, 28 Jan 2018 17:27:50 -0500 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: Dan Carpenter , Greg Kroah-Hartman , Sasha Levin Subject: [PATCH AUTOSEL for 4.14 082/100] staging: ccree: Uninitialized return in ssi_ahash_import() Date: Sun, 28 Jan 2018 22:26:52 +0000 Message-ID: <20180128222547.7398-82-alexander.levin@microsoft.com> References: <20180128222547.7398-1-alexander.levin@microsoft.com> In-Reply-To: <20180128222547.7398-1-alexander.levin@microsoft.com> Content-Language: en-US Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org List-ID: From: Dan Carpenter [ Upstream commit aece09024414b54158e03aa45f4a4436e7cb996c ] The return value isn't initialized on some success paths. Fixes: c5f39d07860c ("staging: ccree: fix leak of import() after init()") Signed-off-by: Dan Carpenter Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/staging/ccree/ssi_hash.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/ccree/ssi_hash.c b/drivers/staging/ccree/ssi_h= ash.c index f72ca485c86f..e266a70a1b32 100644 --- a/drivers/staging/ccree/ssi_hash.c +++ b/drivers/staging/ccree/ssi_hash.c @@ -1781,7 +1781,7 @@ static int ssi_ahash_import(struct ahash_request *req= , const void *in) struct device *dev =3D &ctx->drvdata->plat_dev->dev; struct ahash_req_ctx *state =3D ahash_request_ctx(req); u32 tmp; - int rc; + int rc =3D 0; =20 memcpy(&tmp, in, sizeof(u32)); if (tmp !=3D CC_EXPORT_MAGIC) { --=20 2.11.0