aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/r8169.c
diff options
context:
space:
mode:
authorfrançois romieu <romieu@fr.zoreil.com>2009-08-10 15:43:29 -0400
committerDavid S. Miller <davem@davemloft.net>2009-08-13 01:13:21 -0400
commit8c7006aa94bea415cd7f8c5fa8df9d3f261bd314 (patch)
tree91d533fb8346f0d1e02853685fc8789b86afc04d /drivers/net/r8169.c
parent21d57363201857bd8c5c0ad0ebc795134d632195 (diff)
r8169: phy init for the 8169sce
Synced with Realtek's 6.011.00 r8169 driver. Signed-off-by: Francois Romieu <romieu@fr.zoreil.com> Cc: Edward Hsu <edward_hsu@realtek.com.tw> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/r8169.c')
-rw-r--r--drivers/net/r8169.c56
1 files changed, 56 insertions, 0 deletions
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index 6c4b879497d8..86722886ae47 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -1389,6 +1389,59 @@ static void rtl8169sb_hw_phy_config(void __iomem *ioaddr)
1389 rtl_phy_write(ioaddr, phy_reg_init, ARRAY_SIZE(phy_reg_init)); 1389 rtl_phy_write(ioaddr, phy_reg_init, ARRAY_SIZE(phy_reg_init));
1390} 1390}
1391 1391
1392static void rtl8169sce_hw_phy_config(void __iomem *ioaddr)
1393{
1394 struct phy_reg phy_reg_init[] = {
1395 { 0x1f, 0x0001 },
1396 { 0x04, 0x0000 },
1397 { 0x03, 0x00a1 },
1398 { 0x02, 0x0008 },
1399 { 0x01, 0x0120 },
1400 { 0x00, 0x1000 },
1401 { 0x04, 0x0800 },
1402 { 0x04, 0x9000 },
1403 { 0x03, 0x802f },
1404 { 0x02, 0x4f02 },
1405 { 0x01, 0x0409 },
1406 { 0x00, 0xf099 },
1407 { 0x04, 0x9800 },
1408 { 0x04, 0xa000 },
1409 { 0x03, 0xdf01 },
1410 { 0x02, 0xdf20 },
1411 { 0x01, 0xff95 },
1412 { 0x00, 0xba00 },
1413 { 0x04, 0xa800 },
1414 { 0x04, 0xf000 },
1415 { 0x03, 0xdf01 },
1416 { 0x02, 0xdf20 },
1417 { 0x01, 0x101a },
1418 { 0x00, 0xa0ff },
1419 { 0x04, 0xf800 },
1420 { 0x04, 0x0000 },
1421 { 0x1f, 0x0000 },
1422
1423 { 0x1f, 0x0001 },
1424 { 0x0b, 0x8480 },
1425 { 0x1f, 0x0000 },
1426
1427 { 0x1f, 0x0001 },
1428 { 0x18, 0x67c7 },
1429 { 0x04, 0x2000 },
1430 { 0x03, 0x002f },
1431 { 0x02, 0x4360 },
1432 { 0x01, 0x0109 },
1433 { 0x00, 0x3022 },
1434 { 0x04, 0x2800 },
1435 { 0x1f, 0x0000 },
1436
1437 { 0x1f, 0x0001 },
1438 { 0x17, 0x0cc0 },
1439 { 0x1f, 0x0000 }
1440 };
1441
1442 rtl_phy_write(ioaddr, phy_reg_init, ARRAY_SIZE(phy_reg_init));
1443}
1444
1392static void rtl8168bb_hw_phy_config(void __iomem *ioaddr) 1445static void rtl8168bb_hw_phy_config(void __iomem *ioaddr)
1393{ 1446{
1394 struct phy_reg phy_reg_init[] = { 1447 struct phy_reg phy_reg_init[] = {
@@ -1628,6 +1681,9 @@ static void rtl_hw_phy_config(struct net_device *dev)
1628 case RTL_GIGA_MAC_VER_04: 1681 case RTL_GIGA_MAC_VER_04:
1629 rtl8169sb_hw_phy_config(ioaddr); 1682 rtl8169sb_hw_phy_config(ioaddr);
1630 break; 1683 break;
1684 case RTL_GIGA_MAC_VER_06:
1685 rtl8169sce_hw_phy_config(ioaddr);
1686 break;
1631 case RTL_GIGA_MAC_VER_07: 1687 case RTL_GIGA_MAC_VER_07:
1632 case RTL_GIGA_MAC_VER_08: 1688 case RTL_GIGA_MAC_VER_08:
1633 case RTL_GIGA_MAC_VER_09: 1689 case RTL_GIGA_MAC_VER_09: