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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DF99C433FE for ; Mon, 14 Nov 2022 07:24:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235938AbiKNHYR (ORCPT ); Mon, 14 Nov 2022 02:24:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58206 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235493AbiKNHYP (ORCPT ); Mon, 14 Nov 2022 02:24:15 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB78E6347 for ; Sun, 13 Nov 2022 23:24:14 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 97F8CB80D1C for ; Mon, 14 Nov 2022 07:24:13 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AE129C433D6; Mon, 14 Nov 2022 07:24:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1668410652; bh=KXz6ld+3kTxPSSYyFuR175o0LcKYCqmL723g/hyfaCw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=JdW6pBagwtPiOf5F0zbXlRVhY+hwq3kZ9Mck1JCKkEbtQbrVeSlxddBgxELpe4aXC X2qvf1R5YUe/n20z0EjFbiXLOgsH+XCF0D6TZs0bgXhR7qgEYY527TF1pc1gByXPTg dwlrhB4eF1Dk6aEQa1EPSDNV9uACVvDzSMmuYBK8= Date: Mon, 14 Nov 2022 08:24:09 +0100 From: Greg KH To: Gaosheng Cui Cc: dinguyen@kernel.org, richard.gong@intel.com, atull@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] firmware: stratix10-svc: Fix IS_ERR() vs NULL check in stratix10_svc_drv_probe() Message-ID: References: <20221114025921.1194834-1-cuigaosheng1@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221114025921.1194834-1-cuigaosheng1@huawei.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Nov 14, 2022 at 10:59:21AM +0800, Gaosheng Cui wrote: > The svc_create_memory_pool() returns an ERR_PTR() on failure, we should use > IS_ERR() to check the return value, and return it on failure. How was this found and tested? thanks, greg k-h