Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci Only 82571 shares port 0 of EEMNGCTL_CFGDONE.



details:   https://anonhg.NetBSD.org/src/rev/af4706230ab5
branches:  trunk
changeset: 755851:af4706230ab5
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Fri Jun 25 04:35:54 2010 +0000

description:
Only 82571 shares port 0 of EEMNGCTL_CFGDONE.

diffstat:

 sys/dev/pci/if_wm.c |  10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diffs (31 lines):

diff -r 1b11e1301982 -r af4706230ab5 sys/dev/pci/if_wm.c
--- a/sys/dev/pci/if_wm.c       Fri Jun 25 04:16:28 2010 +0000
+++ b/sys/dev/pci/if_wm.c       Fri Jun 25 04:35:54 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_wm.c,v 1.208 2010/06/25 04:03:14 msaitoh Exp $      */
+/*     $NetBSD: if_wm.c,v 1.209 2010/06/25 04:35:54 msaitoh Exp $      */
 
 /*
  * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -76,7 +76,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.208 2010/06/25 04:03:14 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.209 2010/06/25 04:35:54 msaitoh Exp $");
 
 #include "rnd.h"
 
@@ -4310,7 +4310,11 @@
        case WM_T_82576:
        case WM_T_82580:
        case WM_T_82580ER:
-               mask = EEMNGCTL_CFGDONE_0 << sc->sc_funcid;
+               if (sc->sc_type == WM_T_82571) {
+                       /* Only 82571 shares port 0 */
+                       mask = EEMNGCTL_CFGDONE_0;
+               } else
+                       mask = EEMNGCTL_CFGDONE_0 << sc->sc_funcid;
                for (i = 0; i < WM_PHY_CFG_TIMEOUT; i++) {
                        if (CSR_READ(sc, WMREG_EEMNGCTL) & mask)
                                break;



Home | Main Index | Thread Index | Old Index