summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/ibm/emac/rgmii.c
diff options
context:
space:
mode:
authorIvan Mikhaylov <ivan@ru.ibm.com>2014-05-26 22:24:17 +0400
committerDavid S. Miller <davem@davemloft.net>2014-05-30 16:29:57 -0700
commitfaacd3af0cf4a3ef5565da86038812a25f6fe9eb (patch)
treea13718929cf5cb96e244ac6457495581fb562fb1 /drivers/net/ethernet/ibm/emac/rgmii.c
parent8646224cdb945eca4293e2131e5be47930ce3e80 (diff)
downloadlinux-faacd3af0cf4a3ef5565da86038812a25f6fe9eb.tar.bz2
emac: add missing support of 10mbit in emac/rgmii
In chips of emac/rgmii b'000' for 0/1 channel isn't suitable which resulted in non working network interface in this mode. Signed-off-by: Ivan Mikhaylov <ivan@ru.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ibm/emac/rgmii.c')
-rw-r--r--drivers/net/ethernet/ibm/emac/rgmii.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/ibm/emac/rgmii.c b/drivers/net/ethernet/ibm/emac/rgmii.c
index 4fb2f96da23b..a01182cce965 100644
--- a/drivers/net/ethernet/ibm/emac/rgmii.c
+++ b/drivers/net/ethernet/ibm/emac/rgmii.c
@@ -45,6 +45,7 @@
/* RGMIIx_SSR */
#define RGMII_SSR_MASK(idx) (0x7 << ((idx) * 8))
+#define RGMII_SSR_10(idx) (0x1 << ((idx) * 8))
#define RGMII_SSR_100(idx) (0x2 << ((idx) * 8))
#define RGMII_SSR_1000(idx) (0x4 << ((idx) * 8))
@@ -139,6 +140,8 @@ void rgmii_set_speed(struct platform_device *ofdev, int input, int speed)
ssr |= RGMII_SSR_1000(input);
else if (speed == SPEED_100)
ssr |= RGMII_SSR_100(input);
+ else if (speed == SPEED_10)
+ ssr |= RGMII_SSR_10(input);
out_be32(&p->ssr, ssr);