From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9A6D9C433F5 for ; Fri, 17 Sep 2021 03:21:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7BF2D6103C for ; Fri, 17 Sep 2021 03:21:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243806AbhIQDWe (ORCPT ); Thu, 16 Sep 2021 23:22:34 -0400 Received: from helcar.hmeau.com ([216.24.177.18]:55254 "EHLO deadmen.hmeau.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243767AbhIQDWe (ORCPT ); Thu, 16 Sep 2021 23:22:34 -0400 Received: from gondobar.mordor.me.apana.org.au ([192.168.128.4] helo=gondobar) by deadmen.hmeau.com with esmtp (Exim 4.92 #5 (Debian)) id 1mR4R3-0006FT-LY; Fri, 17 Sep 2021 11:21:09 +0800 Received: from herbert by gondobar with local (Exim 4.92) (envelope-from ) id 1mR4R3-0001m8-Il; Fri, 17 Sep 2021 11:21:09 +0800 Date: Fri, 17 Sep 2021 11:21:09 +0800 From: Herbert Xu To: Colin King Cc: "David S . Miller" , linux-crypto@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] crypto: img-hash: remove need for error return variable ret Message-ID: <20210917032109.GG6559@gondor.apana.org.au> References: <20210910121532.50366-1-colin.king@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210910121532.50366-1-colin.king@canonical.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Sep 10, 2021 at 01:15:32PM +0100, Colin King wrote: > From: Colin Ian King > > The assignment to error return variable ret and then the jump to > an error exit path can be simplified by just returning the error > return at the failure point. This allows variable ret and the > error return path to be removed. This cleans up a static analysis > warninng that variable ret is being assigned (value never being > used) and being re-assigned later. > > Addresses-Coverity: ("Unused value") > Signed-off-by: Colin Ian King > --- > drivers/crypto/img-hash.c | 7 +------ > 1 file changed, 1 insertion(+), 6 deletions(-) Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt