From nobody@FreeBSD.org  Sat Jun 19 04:19:00 2010
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 72B70106566C
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 19 Jun 2010 04:19:00 +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 484798FC0C
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 19 Jun 2010 04:19:00 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o5J4IxE1091462
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 19 Jun 2010 04:18:59 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id o5J4Ix6x091461;
	Sat, 19 Jun 2010 04:18:59 GMT
	(envelope-from nobody)
Message-Id: <201006190418.o5J4Ix6x091461@www.freebsd.org>
Date: Sat, 19 Jun 2010 04:18:59 GMT
From: Curtis Hacker <hakcenter@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: em Receive errors / CRC Errors / Alignment Errors
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         147989
>Category:       kern
>Synopsis:       [em] em Receive errors / CRC Errors / Alignment Errors
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    jfv
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jun 19 04:20:01 UTC 2010
>Closed-Date:    
>Last-Modified:  Mon Aug 23 14:31:15 UTC 2010
>Originator:     Curtis Hacker
>Release:        8.1-PRERELEASE
>Organization:
>Environment:
FreeBSD ds-map.net 8.1-PRERELEASE FreeBSD 8.1-PRERELEASE #2: Fri Jun 18 15:58:39 CDT 2010     root@ds-map.net:/usr/obj/usr/src/sys/CUSTOM  i386
>Description:
I'm getting huge Ierrs through netstat -i on my em device.

I really never update the machine, but I guess since last kernel/world update this happened. I really can't be very descriptive in that area since I'm not exactly sure when. I just tried to do some portupgrades today and noticed the awful receive speed of 15kb/sec.

I have a custom kernel with just altq / hz=1000 / polling enabled. Everything else is generic.

Make.conf:
CPUTYPE?=pentium4.

I've disabled polling.. hasn't helped.
I've removed rxcsum / txcsum.. hasn't helped.
Disabling pf rules hasn't helped.
Unloading pf module hasn't helped.
I've removed all sysctl tweaks of buffers etc.. nada
I've tried :
/boot/loader.conf
hw.em.rxd=4096
hw.em.txd=4096
hw.em.rx_process_limit="-1"
dev.em.0.rx_int_delay: 250
dev.em.0.tx_int_delay: 250
dev.em.0.rx_abs_int_delay: 250
dev.em.0.tx_abs_int_delay: 250

Still hasn't helped.
I've just recently compiled the smp em module from http://people.yandex-team.ru/~wawa/

I really can't seem to debug this machine. It gets HORRIBLE receiving.. yet tx is perfectly fine. Unfortunatly I can't debug the machine in person its on a colo out of state, but I assume the switch / cable is fine.

pciconf -lcv
em0@pci0:0:8:0: class=0x020000 card=0x004e8086 chip=0x100e8086 rev=0x02 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Gigabit Ethernet Controller (82540EM)'
    class      = network
    subclass   = ethernet
    cap 01[dc] = powerspec 2  supports D0 D3  current D0
    cap 07[e4] = PCI-X supports 2048 burst read, 1 split transaction
    cap 05[f0] = MSI supports 1 message, 64 bit

dmesg
em0: link state changed to UP
em0: Excessive collisions = 0
em0: Sequence errors = 0
em0: Defer count = 0
em0: Missed Packets = 0
em0: Receive No Buffers = 0
em0: Receive Length Errors = 0
em0: Receive errors = 240
em0: Crc errors = 289
em0: Alignment errors = 7
em0: Collision/Carrier extension errors = 0
em0: RX overruns = 0
em0: watchdog timeouts = 0
em0: RX MSIX IRQ = 0 TX MSIX IRQ = 0 LINK MSIX IRQ = 0
em0: XON Rcvd = 0
em0: XON Xmtd = 0
em0: XOFF Rcvd = 0
em0: XOFF Xmtd = 0
em0: Good Packets Rcvd = 10562
em0: Good Packets Xmtd = 10386
>How-To-Repeat:

>Fix:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-i386->freebsd-net 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Mon Jun 21 03:25:47 UTC 2010 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=147989 
Responsible-Changed-From-To: freebsd-net->jfv 
Responsible-Changed-By: andre 
Responsible-Changed-When: Mon Aug 23 14:30:51 UTC 2010 
Responsible-Changed-Why:  
Over to maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=147989 
>Unformatted:
