[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20241120105741.bivv5yvsetic55x4@DEN-DL-M70577>
Date: Wed, 20 Nov 2024 10:57:41 +0000
From: Daniel Machon <daniel.machon@...rochip.com>
To: "Russell King (Oracle)" <linux@...linux.org.uk>
CC: <UNGLinuxDriver@...rochip.com>, Andrew Lunn <andrew+netdev@...n.ch>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, "Lars
Povlsen" <lars.povlsen@...rochip.com>, Steen Hegelund
<Steen.Hegelund@...rochip.com>, Horatiu Vultur
<horatiu.vultur@...rochip.com>, <jacob.e.keller@...el.com>,
<robh@...nel.org>, <krzk+dt@...nel.org>, <conor+dt@...nel.org>,
<devicetree@...r.kernel.org>, <netdev@...r.kernel.org>,
<linux-kernel@...r.kernel.org>, <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH net-next v3 4/8] net: sparx5: use
phy_interface_mode_is_rgmii()
> Hi,
>
> On Mon, Nov 18, 2024 at 02:00:50PM +0100, Daniel Machon wrote:
> > diff --git a/drivers/net/ethernet/microchip/sparx5/sparx5_phylink.c b/drivers/net/ethernet/microchip/sparx5/sparx5_phylink.c
> > index f8562c1a894d..cb55e05e5611 100644
> > --- a/drivers/net/ethernet/microchip/sparx5/sparx5_phylink.c
> > +++ b/drivers/net/ethernet/microchip/sparx5/sparx5_phylink.c
> > @@ -32,6 +32,9 @@ sparx5_phylink_mac_select_pcs(struct phylink_config *config,
> > {
> > struct sparx5_port *port = netdev_priv(to_net_dev(config->dev));
> >
> > + if (phy_interface_mode_is_rgmii(interface))
> > + return NULL;
> > +
> > return &port->phylink_pcs;
>
> Maybe turn this into positive logic - return the PCS only when the
> interface mode requires the PCS?
Sure. I can flip the logic and return the PCS for the interface modes that are
advertised as supported.
/Daniel
Powered by blists - more mailing lists