[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YIgGbYtJtq1EnIKD@lunn.ch>
Date: Tue, 27 Apr 2021 14:41:17 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Tobias Waldekranz <tobias@...dekranz.com>
Cc: davem@...emloft.net, kuba@...nel.org, vivien.didelot@...il.com,
f.fainelli@...il.com, olteanv@...il.com, netdev@...r.kernel.org
Subject: Re: [PATCH net-next] net: dsa: mv88e6xxx: Fix 6095/6097/6185 ports
in non-SERDES CMODE
On Mon, Apr 26, 2021 at 06:17:34PM +0200, Tobias Waldekranz wrote:
> The .serdes_get_lane op used the magic value 0xff to indicate a valid
> SERDES lane and 0 signaled that a non-SERDES mode was set on the port.
>
> Unfortunately, "0" is also a valid lane ID, so even when these ports
> where configured to e.g. RGMII the driver would set them up as SERDES
> ports.
>
> - Replace 0xff with 0 to indicate a valid lane ID. The number is on
> the one hand just as arbitrary, but it is at least the first valid one
> and therefore less of a surprise.
>
> - Follow the other .serdes_get_lane implementations and return -ENODEV
> in the case where no SERDES is assigned to the port.
>
> Fixes: f5be107c3338 ("net: dsa: mv88e6xxx: Support serdes ports on MV88E6097/6095/6185")
> Signed-off-by: Tobias Waldekranz <tobias@...dekranz.com>
Reviewed-by: Andrew Lunn <andrew@...n.ch>
Andrew
Powered by blists - more mailing lists