From owner-freebsd-bugs@FreeBSD.ORG Wed Sep 12 01:30:02 2007 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9CED316A419 for ; Wed, 12 Sep 2007 01:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 6BDC213C457 for ; Wed, 12 Sep 2007 01:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.1/8.14.1) with ESMTP id l8C1U2mP059897 for ; Wed, 12 Sep 2007 01:30:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.1/8.14.1/Submit) id l8C1U2wm059896; Wed, 12 Sep 2007 01:30:02 GMT (envelope-from gnats) Resent-Date: Wed, 12 Sep 2007 01:30:02 GMT Resent-Message-Id: <200709120130.l8C1U2wm059896@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Mark Derbyshire Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AA49616A418 for ; Wed, 12 Sep 2007 01:27:20 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 8831113C45A for ; Wed, 12 Sep 2007 01:27:20 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.1/8.14.1) with ESMTP id l8C1RKhP035234 for ; Wed, 12 Sep 2007 01:27:20 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.1/8.14.1/Submit) id l8C1RKLC035233; Wed, 12 Sep 2007 01:27:20 GMT (envelope-from nobody) Message-Id: <200709120127.l8C1RKLC035233@www.freebsd.org> Date: Wed, 12 Sep 2007 01:27:20 GMT From: Mark Derbyshire To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/116295: nfe driver hangs on boot (MSI K9N SLI Platinum) X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Sep 2007 01:30:02 -0000 >Number: 116295 >Category: kern >Synopsis: nfe driver hangs on boot (MSI K9N SLI Platinum) >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Sep 12 01:30:02 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Mark Derbyshire >Release: 7-CURRENT/6.2-RELEASE backport >Organization: >Environment: FreeBSD freebsd.taom.com 6.2-RELEASE FreeBSD 6.2-RELEASE #10: Tue Sep 11 17:00:01 MDT 2007 root@freebsd.taom.com:/usr/obj/usr/src/sys/TAOM amd64 >Description: Driver hangs in an apparent interrupt loop on boot in nfe_int_task with the MSI K9N SLI Platinum motherboard. It seems to work fine on other MCPxx-based boards I tried. If nfe0 is not plugged to a live switch, the boot will succeed. However when nfe0 is plugged into a GbE, full-duplex switch it hangs every time. It does not matter whether nfe1 is plugged in for either of these cases. Revision 1.14 of if_nfe.c does not have this problem. Revision 1.17 appears to have introduced the bug. >How-To-Repeat: Plug nfe0 from a MSI K9N SLI Platinum motherboard into a GbE switch and boot the system. >Fix: --- if_nfe.c.orig 2007-07-23 19:11:00.000000000 -0600 +++ if_nfe.c 2007-09-11 19:24:58.000000000 -0600 @@ -1930,18 +1930,18 @@ } #endif - if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { - NFE_UNLOCK(sc); - nfe_enable_intr(sc); - return; - } - if (r & NFE_IRQ_LINK) { NFE_READ(sc, NFE_PHY_STATUS); NFE_WRITE(sc, NFE_PHY_STATUS, 0xf); DPRINTF(sc, "link state changed\n"); } + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + NFE_UNLOCK(sc); + nfe_enable_intr(sc); + return; + } + domore = 0; /* check Rx ring */ if (sc->nfe_framesize > MCLBYTES - ETHER_HDR_LEN) >Release-Note: >Audit-Trail: >Unformatted: