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 1C426EE3F3F for ; Tue, 12 Sep 2023 22:21:46 +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=zHyyCJ4z/8CaN1l4+wBrWAmEZldo1JhhtAlFSg6WHpQ=; b=2JQhmJ7zLMa8Dw LIVUg0V/H10Dx3NEDKOguPX6Hly+cP8aR74uF069dVcY5trlNYk1gp7Lxw9wIhYlhaVfoEKgr/ieC KdFT/WQ+QIJ3DPCSMjov4mO65So4Jn5Joy/HqBlN2kczxKJdAn2LjeQNLbkM6+RnlQ5og/bK68yL2 X0NN0HfCDD84L6ZkWnOptHhgQrpEWecfPE445n3EP22m3t0xFTdEGX65Fpy6FD1g95LXd1PeZrTEr HcTO8YV2g6cDM/2DjcSYUXwG8peNmV9mx3Okkl/yo9nCDCgvSa0k25jkc1DBw53HQC+pFi6c73YQD yfCeQ00Gt0HByUg76KFg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qgBl5-004BkH-24; Tue, 12 Sep 2023 22:21:23 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:32c8:5054:ff:fe00:142]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qgBl1-004BjC-1h for linux-arm-kernel@lists.infradead.org; Tue, 12 Sep 2023 22:21:21 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=J0yxfTWymB169xV/I/6SashaKoLIMch1mt00vHpWz7I=; b=G5AEZG1C4dGZYDR9EdV0zvXIEO OjzevHR9Nsj07ek/oNgYe2EMcfsXQcfjUGlcJziU4VgFtaPpXzsrPVKr9Ssz5K2dIawaqwrPFAMET ISMii6Cr7jc1duPf51ciyzTHGYFWmhOVEXrXfPvQar6L8rdcAqVRAI6lM9UkLoaIvO+1hJWrmu/FQ uHsHONrGPRatPXwRUqm33YTBWiJDS17ehqihLqqLE7crTKO1/nWcouR6lNPKsWxZnRPTqVxMcgRIm AUPgu3vOiXts2VEEqAyVTJgnadzL635iW+7M4R7cZUhDFFtmw7cFYYqiAXbaxP0W/QSBBO4LsjXSx pxU0de+g==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:53678) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1qgBkh-0001hY-0c; Tue, 12 Sep 2023 23:20:59 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1qgBkd-00035r-8O; Tue, 12 Sep 2023 23:20:55 +0100 Date: Tue, 12 Sep 2023 23:20:55 +0100 From: "Russell King (Oracle)" To: Simon Horman Cc: Alexandre Torgue , Jose Abreu , Alexei Starovoitov , bpf@vger.kernel.org, Daniel Borkmann , "David S. Miller" , Emil Renner Berthing , Eric Dumazet , Fabio Estevam , Jakub Kicinski , Jesper Dangaard Brouer , John Fastabend , linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, Maxime Coquelin , netdev@vger.kernel.org, NXP Linux Team , Paolo Abeni , Pengutronix Kernel Team , Samin Guo , Sascha Hauer , Shawn Guo Subject: Re: [PATCH net-next 1/6] net: stmmac: add platform library Message-ID: References: <20230912145227.GE401982@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230912145227.GE401982@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230912_152119_567088_4E5BE670 X-CRM114-Status: GOOD ( 16.25 ) 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 Tue, Sep 12, 2023 at 04:52:27PM +0200, Simon Horman wrote: > On Mon, Sep 11, 2023 at 04:29:11PM +0100, Russell King (Oracle) wrote: > > + default: > > + return -ENOTSUPP; > > Checkpatch seems to think that EOPNOTSUPP would be more appropriate > as "ENOTSUPP is not a SUSV4 error code". It needs to be an error code that clk_set_rate() below isn't going to return - because if clk_set_rate() does return it, then the users are going to end up issuing an incorrect error message to the user. I suspect clk_set_rate() could quite legitimately return -EOPNOTSUPP or -EINVAL. Sadly, the CCF implementation of clk_set_rate() doesn't detail what errors it could return, but it looks like -EBUSY, -EINVAL, or something from pm_runtime_resume_and_get(). Interestingly, while looking at this, pm_runtime_resume_and_get() can return '1' if e.g. rpm is disabled and the device is active. It looks to me like CCF treats that as an error in multiple locations. > > + } > > + > > + return clk_set_rate(tx_clk, rate); > > +} > > +EXPORT_SYMBOL_GPL(dwmac_set_tx_clk_gmii); -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last! _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel