Module Name: src Committed By: msaitoh Date: Wed Nov 7 08:17:19 UTC 2012
Modified Files: src/sys/dev/pci: if_wm.c Log Message: Fix a bug that PHY isn't set to low-power mode on PCH and PCH2. To generate a diff of this commit: cvs rdiff -u -r1.236 -r1.237 src/sys/dev/pci/if_wm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/pci/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.236 src/sys/dev/pci/if_wm.c:1.237 --- src/sys/dev/pci/if_wm.c:1.236 Fri Oct 12 11:24:44 2012 +++ src/sys/dev/pci/if_wm.c Wed Nov 7 08:17:18 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.236 2012/10/12 11:24:44 msaitoh Exp $ */ +/* $NetBSD: if_wm.c,v 1.237 2012/11/07 08:17:18 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.236 2012/10/12 11:24:44 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.237 2012/11/07 08:17:18 msaitoh Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -4372,7 +4372,7 @@ wm_init(struct ifnet *ifp) reg = CSR_READ(sc, WMREG_CTRL_EXT); /* Enable PHY low-power state when MAC is at D3 w/o WoL */ - if ((sc->sc_type == WM_T_PCH) && (sc->sc_type == WM_T_PCH2)) + if ((sc->sc_type == WM_T_PCH) || (sc->sc_type == WM_T_PCH2)) CSR_WRITE(sc, WMREG_CTRL_EXT, reg | CTRL_EXT_PHYPDEN); /* Initialize the transmit descriptor ring. */