diff options
author | wpaul <wpaul@FreeBSD.org> | 1999-08-29 15:42:04 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 1999-08-29 15:42:04 +0000 |
commit | c880bbe674ca198bf53958c6ebe7d79cfc36b1f7 (patch) | |
tree | d46d4d7bdda0eea175090600568da2c323261d92 /sys/dev/mii/exphy.c | |
parent | e343cf19611a68f1f961aaa5030fbc86e632d250 (diff) | |
download | FreeBSD-src-c880bbe674ca198bf53958c6ebe7d79cfc36b1f7.zip FreeBSD-src-c880bbe674ca198bf53958c6ebe7d79cfc36b1f7.tar.gz |
The ASIC on the 3c905C appears to be manufactured by Broadcom (previous
ones were made by Lucent). The Broadcom chip also appears to use an
internal PHY made by Broadcom which uses the Broadcom OUI. This is different
from previous ASICs which always returned 0 in the PHY ID registers.
To account for this, I added the necessary ID values for the Broadcom
PHY so that it can be detected and attached using the 3Com PHY driver
instead of defaulting to the generic one.
Diffstat (limited to 'sys/dev/mii/exphy.c')
-rw-r--r-- | sys/dev/mii/exphy.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sys/dev/mii/exphy.c b/sys/dev/mii/exphy.c index 9284c7a..ddf7d82 100644 --- a/sys/dev/mii/exphy.c +++ b/sys/dev/mii/exphy.c @@ -89,7 +89,7 @@ #if !defined(lint) static const char rcsid[] = - "$FreeBSD$"; + "$Id: exphy.c,v 1.1 1999/08/21 17:40:41 wpaul Exp $"; #endif static int exphy_probe __P((device_t)); @@ -130,8 +130,10 @@ static int exphy_probe(dev) /* * Argh, 3Com PHY reports oui == 0 model == 0! */ - if (MII_OUI(ma->mii_id1, ma->mii_id2) != 0 || - MII_MODEL(ma->mii_id2) != 0) + if ((MII_OUI(ma->mii_id1, ma->mii_id2) != 0 || + MII_MODEL(ma->mii_id2) != 0) && + (MII_OUI(ma->mii_id1, ma->mii_id2) != MII_OUI_BROADCOM || + MII_MODEL(ma->mii_id2) != MII_MODEL_BROADCOM_3c905Cphy)) return (ENXIO); /* @@ -140,7 +142,10 @@ static int exphy_probe(dev) if (strcmp(device_get_name(parent), "xl") != 0) return (ENXIO); - device_set_desc(dev, "3Com internal media interface"); + if (MII_OUI(ma->mii_id1, ma->mii_id2) == 0) + device_set_desc(dev, "3Com internal media interface"); + else + device_set_desc(dev, MII_STR_BROADCOM_3c905Cphy); return (0); } |