[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Zh5ogZ433lrUOi9b@shell.armlinux.org.uk>
Date: Tue, 16 Apr 2024 13:01:05 +0100
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Romain Gantois <romain.gantois@...tlin.com>
Cc: Serge Semin <fancer.lancer@...il.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>,
Jose Abreu <joabreu@...opsys.com>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Yanteng Si <siyanteng@...ngson.cn>,
Maxime Coquelin <mcoquelin.stm32@...il.com>,
Simon Horman <horms@...nel.org>,
Huacai Chen <chenhuacai@...nel.org>, Chen-Yu Tsai <wens@...e.org>,
Jernej Skrabec <jernej.skrabec@...il.com>,
Samuel Holland <samuel@...lland.org>, netdev@...r.kernel.org,
linux-stm32@...md-mailman.stormreply.com,
linux-arm-kernel@...ts.infradead.org, linux-sunxi@...ts.linux.dev,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next 4/4] net: stmmac: Move MAC caps init to phylink
MAC caps getter
On Tue, Apr 16, 2024 at 09:56:32AM +0200, Romain Gantois wrote:
> Hi Serge,
>
> On Fri, 12 Apr 2024, Serge Semin wrote:
>
> > +static unsigned long stmmac_mac_get_caps(struct phylink_config *config,
> > + phy_interface_t interface)
> > +{
> > + struct stmmac_priv *priv = netdev_priv(to_net_dev(config->dev));
> > +
> > + /* Get the MAC-specific capabilities */
> > + stmmac_mac_phylink_get_caps(priv);
>
> This is a bit of a nitpick, but the terminology is quite confusing between
> stmmac_mac_phylink_get_caps() and stmmac_mac_get_caps(). Ideally, we could just
> get rid of the whole stmmac_do_void_callback() complexity and just call
> phylink_get_caps() directly. In the meantime, maybe renaming this to
> stmmac_mac_core_get_caps() would be acceptable?
I'd prefer not to do that. If the method is called mac_get_caps() then
I'd much rather have method implementations called foo_mac_get_caps()
which makes grep easier.
So... stmmac_core_mac_get_caps() would be acceptable to me.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
Powered by blists - more mailing lists