[OpenRD Ultimate] e1000phy(88E1149/88E1121) has a initialize issue

From: Norikatsu Shigemura <nork_at_FreeBSD.org>
Date: Sun, 13 Jun 2010 23:37:23 +0900
Hi yongari!

	I have a OpenRD Ultimate, which has two GbE ports - if_mge(4).  But
	I couldn't use mge1 like following.  So I tried to investigate.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Jun 13 05:02:14 sidearms kernel: mge1: watchdog timeout
Jun 13 05:02:14 sidearms kernel: mge1: Timeout on link-up
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

	I found a initialize issue in e1000phy.c.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
--- sys/dev/mii/e1000phy.c.orig	2010-05-01 10:17:15.282196000 +0900
+++ sys/dev/mii/e1000phy.c	2010-06-13 16:19:46.616650536 +0900
_at__at_ -278,6 +278,7 _at__at_
 	case MII_MODEL_MARVELL_E1118:
 		break;
 	case MII_MODEL_MARVELL_E1116:
+	case MII_MODEL_MARVELL_E1149:
 		page = PHY_READ(sc, E1000_EADR);
 		/* Select page 3, LED control register. */
 		PHY_WRITE(sc, E1000_EADR, 3);
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

	I confirmed OK on my environment, OpenRD Ultimate has a 88E1121(I
	saw it, physically):
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Jun 13 15:20:01 sidearms kernel: miibus0: miibus_probe: ma.mii_id1 = 0x141, ma.mii_id2 = 0xcb3
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
	And I confirmed that MII chipset ID is same as 88E1249.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    mge0
        Marvell OBIO Memory:
            4043776000-4043784191
        Marvell OBIO IRQ:
            11
            12
            13
            14
            46
      miibus0
        e1000phy0 pnpinfo oui=0x5043 model=0xb rev=0x3 at phyno=0
    mge1
        Marvell OBIO Memory:
            4043792384-4043800575
        Marvell OBIO IRQ:
            15
            16
            17
            18
            47
      miibus1
        e1000phy1 pnpinfo oui=0x5043 model=0xb rev=0x3 at phyno=1
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -


	BTW, I knew same issue on OpenRD Client, it has a 88E1116R, maybe.
	Sorry, I don't already have it.  I couldn't confirm.
	So accordingly my memo:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
miibus0: ma.mii_id1 = 0x141, ma.mii_id2 = 0xe40
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
	I found many initialize issues on 88E1116R by not existing on
	e1000phy.c.  Maybe 88E1116 = 88E1116R like following:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 		    switch (esc->mii_model) {
 		    case MII_MODEL_MARVELL_E1111:
 		    case MII_MODEL_MARVELL_E1112:
 		    case MII_MODEL_MARVELL_E1116:
+		    case MII_MODEL_MARVELL_E1116R:
 		    case MII_MODEL_MARVELL_E1118:
 		    case MII_MODEL_MARVELL_E1149:
 		    case MII_MODEL_MARVELL_PHYG65G:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
	But there are many points, I don't know that this modify is right.

-- 
Hayabusa, Okaerinasai!

Norikatsu Shigemura <nork_at_FreeBSD.org>
Received on Sun Jun 13 2010 - 12:37:25 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:04 UTC