[PATCH net-next v3 1/3] net: ethernet: mediatek: Add basic PHYLINK support
Russell King - ARM Linux admin
linux at armlinux.org.uk
Sat Aug 24 02:11:06 PDT 2019
On Fri, Aug 23, 2019 at 03:45:14PM +0200, René van Dorst wrote:
> This convert the basics to PHYLINK API.
> SGMII support is not in this patch.
> Signed-off-by: René van Dorst <opensource at vdorst.com>
> * Make link_down() similar as link_up() suggested by Russell King
Yep, almost there, but...
> +static void mtk_mac_link_down(struct phylink_config *config, unsigned int mode,
> + phy_interface_t interface)
> + struct mtk_mac *mac = container_of(config, struct mtk_mac,
> + phylink_config);
> + u32 mcr = mtk_r32(mac->hw, MTK_MAC_MCR(mac->id));
> + mcr &= (MAC_MCR_TX_EN | MAC_MCR_RX_EN);
... this clears all bits _except_ for the tx and rx enable (which will
remain set) - you probably wanted a ~ before the (.
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to speedtest.net: 11.9Mbps down 500kbps up
More information about the Linux-mediatek