[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180905010755.GO29121@lunn.ch>
Date: Wed, 5 Sep 2018 03:07:55 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Moritz Fischer <mdf@...nel.org>
Cc: netdev@...r.kernel.org, davem@...emloft.net, f.fainelli@...il.com,
alex.williams@...com, moritz.fischer@...us.com,
linux-kernel@...r.kernel.org
Subject: Re: [RFC/PATCH] net: nixge: Add PHYLINK support
> -static void nixge_handle_link_change(struct net_device *ndev)
> -{
> - struct nixge_priv *priv = netdev_priv(ndev);
> - struct phy_device *phydev = ndev->phydev;
> -
> - if (phydev->link != priv->link || phydev->speed != priv->speed ||
> - phydev->duplex != priv->duplex) {
> - priv->link = phydev->link;
> - priv->speed = phydev->speed;
> - priv->duplex = phydev->duplex;
> - phy_print_status(phydev);
> - }
> -}
I think this is why you are having trouble with the phylink
callbacks. You currently don't have any configuration of the MAC. You
normally need to tell the MAC what speed it should be doing. What
duplex it should be doing, if the link is up or down, if it should do
pause, or asym pause or no pause, etc.
Andrew
Powered by blists - more mailing lists