[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20200320.085553.875593102765967647.davem@davemloft.net>
Date: Fri, 20 Mar 2020 08:55:53 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: olteanv@...il.com
Cc: netdev@...r.kernel.org, andrew@...n.ch, f.fainelli@...il.com,
vivien.didelot@...il.com, linux@...linux.org.uk
Subject: Re: [PATCH v3 net-next] net: dsa: sja1105: Add support for the
SGMII port
From: Vladimir Oltean <olteanv@...il.com>
Date: Fri, 20 Mar 2020 13:29:37 +0200
> From: Vladimir Oltean <vladimir.oltean@....com>
>
> SJA1105 switches R and S have one SerDes port with an 802.3z
> quasi-compatible PCS, hardwired on port 4. The other ports are still
> MII/RMII/RGMII. The PCS performs rate adaptation to lower link speeds;
> the MAC on this port is hardwired at gigabit. Only full duplex is
> supported.
>
> The SGMII port can be configured as part of the static config tables, as
> well as through a dedicated SPI address region for its pseudo-clause-22
> registers. However it looks like the static configuration is not
> able to change some out-of-reset values (like the value of MII_BMCR), so
> at the end of the day, having code for it is utterly pointless. We are
> just going to use the pseudo-C22 interface.
>
> Because the PCS gets reset when the switch resets, we have to add even
> more restoration logic to sja1105_static_config_reload, otherwise the
> SGMII port breaks after operations such as enabling PTP timestamping
> which require a switch reset.
>
> From PHYLINK perspective, the switch supports *only* SGMII (it doesn't
> support 1000Base-X). It also doesn't expose access to the raw config
> word for in-band AN in registers MII_ADV/MII_LPA.
> It is able to work in the following modes:
> - Forced speed
> - SGMII in-band AN slave (speed received from PHY)
> - SGMII in-band AN master (acting as a PHY)
>
> The latter mode is not supported by this patch. It is even unclear to me
> how that would be described. There is some code for it left in the
> patch, but 'an_master' is always passed as false.
>
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>
Applied, thank you.
Powered by blists - more mailing lists