From owner-freebsd-stable@FreeBSD.ORG Thu Dec 2 00:44:51 2010 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E251106564A for ; Thu, 2 Dec 2010 00:44:51 +0000 (UTC) (envelope-from pyunyh@gmail.com) Received: from mail-gw0-f54.google.com (mail-gw0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id 3FC478FC0C for ; Thu, 2 Dec 2010 00:44:50 +0000 (UTC) Received: by gwj21 with SMTP id 21so4024308gwj.13 for ; Wed, 01 Dec 2010 16:44:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:received:from:date:to:cc :subject:message-id:reply-to:references:mime-version:content-type :content-disposition:in-reply-to:user-agent; bh=G3Qs8L9FMHeVTWVtNbxSFGgCfUh5yqFH7TEvVYXE47o=; b=UE8/BXjW+O5plN3hVo/tkymfeSxo2YCs+fTywEpuDaJDf/sGwTshpVIWVlowGxX0gq jvebR5BeIn3C1wddfOsTY6En2JJT3juvY+wnk8aCiupuGPj+g9K+VNCQskSyDSrT6+gF hCCho5/uRunbIe3Md3Ra3LTxYdNgf0ilt3wUQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:date:to:cc:subject:message-id:reply-to:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=wl61q7h6YC/JPtn/Wcs1fAbHcxM/DGMhjCh4Zu598trhmy/l51iwzJFds3RSUqLO1f 4edM2wHMNfgZY+VyRmk5MfT0pKKudP6Hskgr/mqxmliBHc1y8s8iiZCvzlVzgBnj7yUt 4hTATG9AOJ3b0/pAhNpUOpxfBBAMWFQIeB6qM= Received: by 10.150.196.13 with SMTP id t13mr341996ybf.41.1291250690401; Wed, 01 Dec 2010 16:44:50 -0800 (PST) Received: from pyunyh@gmail.com ([174.35.1.224]) by mx.google.com with ESMTPS id 54sm365179yhl.32.2010.12.01.16.44.47 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 01 Dec 2010 16:44:48 -0800 (PST) Received: by pyunyh@gmail.com (sSMTP sendmail emulation); Wed, 1 Dec 2010 16:44:47 -0800 From: Pyun YongHyeon Date: Wed, 1 Dec 2010 16:44:47 -0800 To: Karl Denninger Message-ID: <20101202004447.GD8893@michelle.cdnetworks.com> References: <4CF6E41F.8060101@denninger.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="MfFXiAuoTsnnDAfZ" Content-Disposition: inline In-Reply-To: <4CF6E41F.8060101@denninger.net> User-Agent: Mutt/1.4.2.3i Cc: freebsd-stable@freebsd.org Subject: Re: Uh, fxp driver broken in current -STABLE build?! X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: pyunyh@gmail.com List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2010 00:44:51 -0000 --MfFXiAuoTsnnDAfZ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Dec 01, 2010 at 06:11:11PM -0600, Karl Denninger wrote: > Works in this kernel, checked out on that day: > > FreeBSD 8.1-STABLE #10: Mon Aug 30 06:44:40 CDT 2010 > karl@FS.denninger.net:/usr/obj/usr/src/sys/KSD-SMP > > fxp0: port 0x1000-0x101f mem > 0x94000000-0x94000fff,0x94100000-0x941fffff irq 21 at device 0.0 on pci6 > fxp0: Enabling Rx lock-up workaround > miibus0: on fxp0 > fxp0: Ethernet address: 00:a0:c9:a4:78:c3 > fxp0: [ITHREAD] > > (and has been running for months, and for a very long time before that) > > Tried to update to today's check-out and got hosed. > > The driver now keeps resetting and sending out "down" and "up" messages > repeatedly, and no traffic flows.... > > This is the ident I have on the current build: > > fxp0: port 0x1000-0x101f mem > 0x94000000-0x94000fff,0x94100000-0x941fffff irq 21 at device 0.0 on pci6 > fxp0: Enabling Rx lock-up workaround > miibus0: on fxp0 > fxp0: Ethernet address: 00:a0:c9:a4:78:c3 > fxp0: [ITHREAD] > > Looks the same..... > > Something was touched though on Nov 30 in the CVS tree. > > It looks like there was a fairly serious commit posted on 10-15, and > some other smaller ones related to VLANs and flow control (which don't > apply to this configuration.) > > I can't find anything else related...... anyone know what's up here? > > Probably need to find this as we're going into the 8.2 RELEASE cycle..... > > DMESG from the failed kernel boot is attached. > Thanks for reporting. Try attached patch. It seems there is a bug in RX lockup detection logic. Your controller is known to RX lockup free so the workaround should not be enabled. Otherwise fxp(4) reinitializes the controller every 15 seconds. --MfFXiAuoTsnnDAfZ Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="fxp.82557.lockup.diff" Index: sys/dev/fxp/if_fxp.c =================================================================== --- sys/dev/fxp/if_fxp.c (revision 216097) +++ sys/dev/fxp/if_fxp.c (working copy) @@ -526,10 +526,12 @@ } /* Receiver lock-up workaround detection. */ - fxp_read_eeprom(sc, &data, 3, 1); - if ((data & 0x03) != 0x03) { - sc->flags |= FXP_FLAG_RXBUG; - device_printf(dev, "Enabling Rx lock-up workaround\n"); + if (sc->revision < FXP_REV_82558_A4) { + fxp_read_eeprom(sc, &data, 3, 1); + if ((data & 0x03) != 0x03) { + sc->flags |= FXP_FLAG_RXBUG; + device_printf(dev, "Enabling Rx lock-up workaround\n"); + } } /* --MfFXiAuoTsnnDAfZ--