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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 975ECEE498D for ; Fri, 18 Aug 2023 18:57:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=dNXePWT/QTFKBva9NAMr+RlhSyHt60zEoTj4cJ8mQS4=; b=H2T2PqQQvoCHJq LUkU03A0cA38aT4kkZmhEsUXJ4WZ9OsT/kB5kFB5nHuEl8E1LSJQN5Ln2jo5V5YbP9FOHDkSocrr5 dhvM3vqO4mL27mC47JEQ+T3XQIQk7Z4fdvqZb9BSv7Y98VDtK/CHdMwZYeP6jBVv/BbYwF30u3vT3 mpxAeFmwoyGwCVBGzSYyOBywF7qOShuSktxtgzuAA848MNYLhSt/aXoXj5TKI3jfqf89RqIGB2oX2 Lt5rmEGM1HCn8rGkdxIY4gQFpiNtECYAGaT4hhyRncuNWfEVxk+TrxgEVe+WjlAy9l1hL1BBBIRYv p78GQxBO/02SwDW+ZZKg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qX4eE-009uDS-33; Fri, 18 Aug 2023 18:56:39 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qX4eC-009uCH-1k for linux-arm-kernel@lists.infradead.org; Fri, 18 Aug 2023 18:56:37 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 96F5A63986; Fri, 18 Aug 2023 18:56:33 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 31A1EC433C8; Fri, 18 Aug 2023 18:56:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1692384993; bh=E2NilpaHDitNnVEICGmFjHWn3jghjuxJfQm6i/3vhf8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=VPqfWylzXUKh/Kkj3LjJyeh0Ozac3H+Cn/tiV7IQzed/3/CD/lwe7q/Xp8nG8BeRg +hs1sgcVjsyKTk4K9rIXw25in0NQ0JfzjXZAQIDho4G0H0P+0c2kw7T1V739G+naab WRpyx3Jm/3s9H5GyUxlHdFj1VCIpDStzqvQ+Za55SckbaVHSXAGHvNAHgLl7kpeWSq ALlgIxGCWLJ4YYQe/DclcF615RAiEF8wnF4KftAp6YjEvQxU/f/HWjzoPqftEPC4PW iDu4z5RjaaB+ZBRczELucbrUOKdIox59e+Qcy5WL9JDtJ5jfuSfEleEwPUj8VLXYDA nA+Dcn9bw695g== Date: Fri, 18 Aug 2023 21:56:26 +0300 From: Leon Romanovsky To: Ruan Jinjie Cc: horatiu.vultur@microchip.com, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, lars.povlsen@microchip.com, Steen.Hegelund@microchip.com, daniel.machon@microchip.com, richardcochran@gmail.com, horms@kernel.org, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH net-next v2 2/3] net: lan966x: Fix return value check for vcap_get_rule() Message-ID: <20230818185626.GG22185@unreal> References: <20230818050505.3634668-1-ruanjinjie@huawei.com> <20230818050505.3634668-3-ruanjinjie@huawei.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230818050505.3634668-3-ruanjinjie@huawei.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230818_115636_623269_5C27E526 X-CRM114-Status: GOOD ( 15.03 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Aug 18, 2023 at 01:05:04PM +0800, Ruan Jinjie wrote: > As Simon Horman suggests, update vcap_get_rule() to always > return an ERR_PTR() and update the error detection conditions to > use IS_ERR(), so use IS_ERR() to fix the return value issue. > > Fixes: 72df3489fb10 ("net: lan966x: Add ptp trap rules") > Signed-off-by: Ruan Jinjie > Suggested-by: Simon Horman > --- > v2: > - Update vcap_get_rule() to always return ERR_PTR instead of checking IS_ERR_OR_NULL() > - Update the commit message. > - Check IS_ERR() instead of NULL. > --- > drivers/net/ethernet/microchip/lan966x/lan966x_ptp.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > Thanks, Reviewed-by: Leon Romanovsky _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel