aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/skge.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/net/skge.c b/drivers/net/skge.c
index bf55a4cfb3d2..67fb19b8fde9 100644
--- a/drivers/net/skge.c
+++ b/drivers/net/skge.c
@@ -1697,6 +1697,7 @@ static void yukon_mac_init(struct skge_hw *hw, int port)
1697 skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_SET); 1697 skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_SET);
1698 skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_CLR); 1698 skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_CLR);
1699 skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_ON | GMC_RST_CLR); 1699 skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_ON | GMC_RST_CLR);
1700
1700 if (skge->autoneg == AUTONEG_DISABLE) { 1701 if (skge->autoneg == AUTONEG_DISABLE) {
1701 reg = GM_GPCR_AU_ALL_DIS; 1702 reg = GM_GPCR_AU_ALL_DIS;
1702 gma_write16(hw, port, GM_GP_CTRL, 1703 gma_write16(hw, port, GM_GP_CTRL,
@@ -1704,16 +1705,23 @@ static void yukon_mac_init(struct skge_hw *hw, int port)
1704 1705
1705 switch (skge->speed) { 1706 switch (skge->speed) {
1706 case SPEED_1000: 1707 case SPEED_1000:
1708 reg &= ~GM_GPCR_SPEED_100;
1707 reg |= GM_GPCR_SPEED_1000; 1709 reg |= GM_GPCR_SPEED_1000;
1708 /* fallthru */ 1710 break;
1709 case SPEED_100: 1711 case SPEED_100:
1712 reg &= ~GM_GPCR_SPEED_1000;
1710 reg |= GM_GPCR_SPEED_100; 1713 reg |= GM_GPCR_SPEED_100;
1714 break;
1715 case SPEED_10:
1716 reg &= ~(GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100);
1717 break;
1711 } 1718 }
1712 1719
1713 if (skge->duplex == DUPLEX_FULL) 1720 if (skge->duplex == DUPLEX_FULL)
1714 reg |= GM_GPCR_DUP_FULL; 1721 reg |= GM_GPCR_DUP_FULL;
1715 } else 1722 } else
1716 reg = GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100 | GM_GPCR_DUP_FULL; 1723 reg = GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100 | GM_GPCR_DUP_FULL;
1724
1717 switch (skge->flow_control) { 1725 switch (skge->flow_control) {
1718 case FLOW_MODE_NONE: 1726 case FLOW_MODE_NONE:
1719 skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_OFF); 1727 skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_OFF);