Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7BBBFC6FA99 for ; Fri, 10 Mar 2023 11:30:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229845AbjCJLav (ORCPT ); Fri, 10 Mar 2023 06:30:51 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49472 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230392AbjCJLaZ (ORCPT ); Fri, 10 Mar 2023 06:30:25 -0500 Received: from 167-179-156-38.a7b39c.syd.nbn.aussiebb.net (167-179-156-38.a7b39c.syd.nbn.aussiebb.net [167.179.156.38]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3EB185FF6; Fri, 10 Mar 2023 03:30:19 -0800 (PST) Received: from loth.rohan.me.apana.org.au ([192.168.167.2]) by formenos.hmeau.com with smtp (Exim 4.94.2 #2 (Debian)) id 1paawk-002Y5q-1D; Fri, 10 Mar 2023 19:30:03 +0800 Received: by loth.rohan.me.apana.org.au (sSMTP sendmail emulation); Fri, 10 Mar 2023 19:30:02 +0800 Date: Fri, 10 Mar 2023 19:30:02 +0800 From: Herbert Xu To: Neal Liu Cc: Joel Stanley , Andrew Jeffery , "David S . Miller" , linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org Subject: Re: [PATCH v2] crypto: aspeed: add error handling if dmam_alloc_coherent() failed Message-ID: References: <20230224020521.3158285-1-neal_liu@aspeedtech.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230224020521.3158285-1-neal_liu@aspeedtech.com> Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Feb 24, 2023 at 10:05:21AM +0800, Neal Liu wrote: > Since the acry_dev->buf_addr may be NULL, add error handling to > prevent any additional access to avoid potential issues. > > Signed-off-by: Neal Liu > --- > Change since v1: remove memzero_explicit() as dmam_alloc_coherent() > returns memory that's already zeroed. > > drivers/crypto/aspeed/aspeed-acry.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) Patch applied. Thanks. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt