Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/mii - Deal with status properly, if BMCR_ISO is set.



details:   https://anonhg.NetBSD.org/src/rev/5855dde1c89f
branches:  trunk
changeset: 573663:5855dde1c89f
user:      kanaoka <kanaoka%NetBSD.org@localhost>
date:      Fri Feb 04 15:17:31 2005 +0000

description:
- Deal with status properly,if BMCR_ISO is set.

Fixes kern/29113.

diffstat:

 sys/dev/mii/rgephy.c |  10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diffs (31 lines):

diff -r e97d0ed2b53a -r 5855dde1c89f sys/dev/mii/rgephy.c
--- a/sys/dev/mii/rgephy.c      Fri Feb 04 15:11:35 2005 +0000
+++ b/sys/dev/mii/rgephy.c      Fri Feb 04 15:17:31 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rgephy.c,v 1.2 2005/01/21 11:55:52 yamt Exp $  */
+/*     $NetBSD: rgephy.c,v 1.3 2005/02/04 15:17:31 kanaoka Exp $       */
 
 /*
  * Copyright (c) 2003
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rgephy.c,v 1.2 2005/01/21 11:55:52 yamt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rgephy.c,v 1.3 2005/02/04 15:17:31 kanaoka Exp $");
 
 
 /*
@@ -349,6 +349,12 @@
 
        bmcr = PHY_READ(sc, RGEPHY_MII_BMCR);
 
+       if (bmcr & RGEPHY_BMCR_ISO) {
+               mii->mii_media_active |= IFM_NONE;
+               mii->mii_media_status = 0;
+               return;
+       }
+
        if (bmcr & RGEPHY_BMCR_LOOP)
                mii->mii_media_active |= IFM_LOOP;
 



Home | Main Index | Thread Index | Old Index