]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
sh_eth: add RGMII support
authorSergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Fri, 18 May 2018 18:30:18 +0000 (21:30 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 20 May 2018 03:24:46 +0000 (23:24 -0400)
The R-Car V3H (AKA R8A77980) GEther controller  adds support for the RGMII
PHY interface mode as a new  value  for the RMII_MII register.

Based on the original (and large) patch by Vladimir Barinov.

Signed-off-by: Vladimir Barinov <vladimir.barinov@cogentembedded.com>
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/renesas/sh_eth.c

index 8dd41e08a6c632ffbf94930e820646eda370701f..d214ec09d40185429591b60893e2409f92936cd3 100644 (file)
@@ -466,6 +466,9 @@ static void sh_eth_select_mii(struct net_device *ndev)
        u32 value;
 
        switch (mdp->phy_interface) {
+       case PHY_INTERFACE_MODE_RGMII ... PHY_INTERFACE_MODE_RGMII_TXID:
+               value = 0x3;
+               break;
        case PHY_INTERFACE_MODE_GMII:
                value = 0x2;
                break;