From owner-freebsd-current@FreeBSD.ORG Tue Feb 13 05:46:09 2007 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CD01316A401 for ; Tue, 13 Feb 2007 05:46:09 +0000 (UTC) (envelope-from pyunyh@gmail.com) Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.239]) by mx1.freebsd.org (Postfix) with ESMTP id 8290313C47E for ; Tue, 13 Feb 2007 05:46:09 +0000 (UTC) (envelope-from pyunyh@gmail.com) Received: by nz-out-0506.google.com with SMTP id i11so1965329nzh for ; Mon, 12 Feb 2007 21:46:09 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:date:from:to:cc:subject:message-id:reply-to:references:mime-version:content-type:content-disposition:in-reply-to:user-agent; b=eHUrEZ2ubn4t0+1j+IbsNMWH4Z6cOIOpvhqhdeZ2fy9+RUaC9MSEBqQmAB5O7mq60dV+/xoyOFBbUSD3Rakzdc1sbLfO7AJ5gWkXJxiqqRCtEnL2NZZRqZPm5WcN9pNXIa8kK9PGpPjju5RNpXLOrtinXpWeg7j1308z8zoJjdQ= Received: by 10.64.199.2 with SMTP id w2mr22373545qbf.1171345568872; Mon, 12 Feb 2007 21:46:08 -0800 (PST) Received: from michelle.cdnetworks.co.kr ( [211.53.35.84]) by mx.google.com with ESMTP id c12sm41833414nzc.2007.02.12.21.46.06; Mon, 12 Feb 2007 21:46:07 -0800 (PST) Received: from michelle.cdnetworks.co.kr (localhost.cdnetworks.co.kr [127.0.0.1]) by michelle.cdnetworks.co.kr (8.13.5/8.13.5) with ESMTP id l1D5m3xg063660 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 13 Feb 2007 14:48:03 +0900 (KST) (envelope-from pyunyh@gmail.com) Received: (from yongari@localhost) by michelle.cdnetworks.co.kr (8.13.5/8.13.5/Submit) id l1D5m2tm063659; Tue, 13 Feb 2007 14:48:02 +0900 (KST) (envelope-from pyunyh@gmail.com) Date: Tue, 13 Feb 2007 14:48:02 +0900 From: Pyun YongHyeon To: Joe Marcus Clarke Message-ID: <20070213054802.GD62412@cdnetworks.co.kr> References: <45D0BB41.9040505@FreeBSD.org> <20070213000922.GA62412@cdnetworks.co.kr> <1171327083.98536.5.camel@shumai.marcuscom.com> <20070213044746.GC62412@cdnetworks.co.kr> <1171344897.98536.14.camel@shumai.marcuscom.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="YiEDa0DAkWCtVeE4" Content-Disposition: inline In-Reply-To: <1171344897.98536.14.camel@shumai.marcuscom.com> User-Agent: Mutt/1.4.2.1i Cc: current@FreeBSD.org Subject: Re: Constant stream of errors on msk0 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: pyunyh@gmail.com List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Feb 2007 05:46:09 -0000 --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Feb 13, 2007 at 12:34:57AM -0500, Joe Marcus Clarke wrote: > On Tue, 2007-02-13 at 13:47 +0900, Pyun YongHyeon wrote: > > On Mon, Feb 12, 2007 at 07:38:03PM -0500, Joe Marcus Clarke wrote: > > > On Tue, 2007-02-13 at 09:09 +0900, Pyun YongHyeon wrote: > > > > On Mon, Feb 12, 2007 at 02:08:49PM -0500, Joe Marcus Clarke wrote: > > > > > -----BEGIN PGP SIGNED MESSAGE----- > > > > > Hash: SHA1 > > > > > > > > > > I recently upgraded my MacBook Pro from -STABLE to -CURRENT. I used to > > > > > be using the Marvell myk driver for my wired ethernet. This driver > > > > > worked fine. I'm now using the built-in msk driver, but this driver > > > > > causes the interface to report a constant stream of input errors. There > > > > > > > > Would you explain this input errors? > > > > > > netstat -i reports steadily increasing input errors (Ierrs) every time > > > packets arrive on the machine. > > > > > > > It looks like link speed/duplex mismatch. > > How about manual configuration? > > (e.g. ifconfig msk0 media 1000baseTX mediaopt full-duplex) > > That was the first thing I though of. I tried all settings from > 100BaseTX half/full to 1000BaseTX half/full to auto. The same problem > was always observed. Additionally, I turned off TSO to see if that made > any difference, and it did not. > Ok, let's see what's happending on your NIC. Try attached patch and let me know the output. > Joe > > -- > Joe Marcus Clarke > FreeBSD GNOME Team :: gnome@FreeBSD.org > FreeNode / #freebsd-gnome > http://www.FreeBSD.org/gnome -- Regards, Pyun YongHyeon --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="msk.debug.patch" Index: if_msk.c =================================================================== RCS file: /home/ncvs/src/sys/dev/msk/if_msk.c,v retrieving revision 1.8 diff -u -r1.8 if_msk.c --- if_msk.c 9 Jan 2007 01:31:22 -0000 1.8 +++ if_msk.c 13 Feb 2007 05:43:55 -0000 @@ -3029,11 +3029,13 @@ cons = sc_if->msk_cdata.msk_rx_cons; do { rxlen = status >> 16; - if ((status & GMR_FS_VLAN) != 0) + if ((status & GMR_FS_VLAN) != 0 && + (ifp->if_capenable & IFCAP_VLAN_HWTAGGING) != 0) rxlen -= ETHER_VLAN_ENCAP_LEN; if (len > sc_if->msk_framesize || ((status & GMR_FS_ANY_ERR) != 0) || ((status & GMR_FS_RX_OK) == 0) || (rxlen != len)) { + printf("0x%08x : %d : %d\n", status, rxlen, len); /* Don't count flow-control packet as errors. */ if ((status & GMR_FS_GOOD_FC) == 0) ifp->if_ierrors++; @@ -3081,7 +3083,8 @@ cons = sc_if->msk_cdata.msk_rx_cons; do { rxlen = status >> 16; - if ((status & GMR_FS_VLAN) != 0) + if ((status & GMR_FS_VLAN) != 0 && + (ifp->if_capenable & IFCAP_VLAN_HWTAGGING) != 0) rxlen -= ETHER_VLAN_ENCAP_LEN; if (len > sc_if->msk_framesize || ((status & GMR_FS_ANY_ERR) != 0) || --YiEDa0DAkWCtVeE4--