From nobody@FreeBSD.org  Tue Oct 15 20:11:03 2002
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id A537637B401
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Oct 2002 20:11:03 -0700 (PDT)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 6580343E6A
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Oct 2002 20:11:03 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.12.6/8.12.6) with ESMTP id g9G3B27R035764
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Oct 2002 20:11:02 -0700 (PDT)
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.12.6/8.12.6/Submit) id g9G3B2Rj035763;
	Tue, 15 Oct 2002 20:11:02 -0700 (PDT)
Message-Id: <200210160311.g9G3B2Rj035763@www.freebsd.org>
Date: Tue, 15 Oct 2002 20:11:02 -0700 (PDT)
From: Yasushi Tamura <tam@math.kobe-u.ac.jp>
To: freebsd-gnats-submit@FreeBSD.org
Subject: lnc network hungup at large traffics on VMware
X-Send-Pr-Version: www-1.0

>Number:         44126
>Category:       kern
>Synopsis:       lnc network hungup at large traffics on VMware
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    paul
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 15 20:20:01 PDT 2002
>Closed-Date:    Mon May 16 11:14:57 GMT 2005
>Last-Modified:  Mon May 16 11:14:57 GMT 2005
>Originator:     Yasushi Tamura
>Release:        4.3-4.7
>Organization:
individual
>Environment:
FreeBSD  4.7-RELEASE FreeBSD 4.7-RELEASE #0: Tue  8 14:22:46 GMT 2002     root@builder.freebsdmail.com:/usr/obj/usr/src/sys/BOOTMFS  i386
>Description:
When I give heavy network trafiics to lnc NIC on VMware,
sometime lnc NIC will fall down not to send packets
to other hosts nor receive packets from other hosts.
But then, lnc can connect ownself host.

>How-To-Repeat:
Start ssh connection with X portforwarding and
start heavy traffic programs(example, netscape, vnc, xdvi,...)
In other case, this problem occur at installing OS,
ports, packages.
>Fix:
After rebooting FreeBSD (VMware not restart),
this problem disappear.
>Release-Note:
>Audit-Trail:

From: Attila Nagy <bra@fsn.hu>
To: freebsd-gnats-submit@FreeBSD.org, <tam@math.kobe-u.ac.jp>
Cc:  
Subject: Re: kern/44126: lnc network hungup at large traffics on VMware
Date: Mon, 25 Nov 2002 11:19:22 +0100 (CET)

 Hello,
 
 This PR isn't really related to the amount of the traffic. I have some
 virtual machines in VMWare, running on Windows XP and all versions of
 FreeBSD (4-STABLE, 5-CURRENT) drop the carrier of lnc after some time.
 
 You won't even need to reboot FreeBSD inside the machine, because an
 ifconfig lnc0 down; ifconfig lnc0 up will fix the problem.
 
 ----------[ Free Software ISOs - http://www.fsn.hu/?f=download ]----------
 Attila Nagy					e-mail: Attila.Nagy@fsn.hu
 Free Software Network (FSN.HU)		  phone @work: +361 210 1415 (194)
 						cell.: +3630 306 6758
 
 

From: Charles Randall <cfriv@yahoo.com>
To: freebsd-gnats-submit@FreeBSD.org
Cc: tam@math.kobe-u.ac.jp, karuhito@cam.hi-ho.ne.jp,
	paul@freebsd-services.com
Subject: Re: kern/44126: lnc network hungup at large traffics on VMware
Date: Thu, 6 Feb 2003 10:24:37 -0800 (PST)

 Having battled this problem many times, I finally
 opened a support incident with vmware.
 
 They've admitted that this is a bug and have assigned
 Bug #18190 to this problem.
 
 I originally repoted this with vmware 0.8 and FreeBSD
 3.2,
 
 http://groups.google.com/groups?selm=199908030045.RAA02341_dingo.cdrom.com%40ns.sol.net
 
 This workaround (which Paul says doesn't make sense)
 seems to work for FreeBSD 4.x (but fails miserably
 with 5.0),
 
 http://groups.google.com/groups?threadm=fa.kuu61sv.1imok1a%40ifi.uio.no
 
 FYI,
 -Charles
 
 
 =====
 Charles F. Randall, IV
 cfr@pobox.com (always forwarded)
 
 __________________________________________________
 Do you Yahoo!?
 Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
 http://mailplus.yahoo.com

From: Gustav Wibling <gustav@vmware.com>
To: "'freebsd-gnats-submit@FreeBSD.org'" <freebsd-gnats-submit@FreeBSD.org>,
	"'tam@math.kobe-u.ac.jp'" <tam@math.kobe-u.ac.jp>
Cc:  
Subject: Re: kern/44126: lnc network hungup at large traffics on VMware (R
	esend)
Date: Fri, 7 Mar 2003 09:52:21 -0800 

 The reason this happens on VMware is due to a race
 in the driver. This race is exposed by virtual hardware
 because things happens more in clusters. 
 
 The problem was caused by the line
 
 outw(sc->rdp, RINT | INEA)
 
 at the end of the lnc_rint function.
 
 What happens is that from the end of the while loop
 to the outw writes/acks the RINT in the LANCE status
 register the receive ring fills up with new data and 
 the RINT written in the status register due to this 
 will be acked without the driver handling the new 
 packets.
 No new RINT interrupts will be generated because the
 hardware is unable to get a valid receive dsc. (The 
 ring is full). The guest won't handle the packets 
 because it received no interrupt from the hardware.
 By removing this line the caller of lnc_rint will do
 a read and an ack and then handle what it read, instead
 of just unconditionally acking. This seems like the
 correct thing to do.
 
 This is very unlikely to happen on real hardware because
 it normally takes time to receive, in this case, 8 packets.
 On virtual hardware this can be done very fast because
 it is mainly a memcpy.
 
 The next release of VMware Workstation will have a 
 workaround for this.
 
 Thanks,
 
 Gustav Wibling
 Member of Tech. Staff
 VMware, Inc.
 
 
 
Responsible-Changed-From-To: freebsd-bugs->paul 
Responsible-Changed-By: matusita 
Responsible-Changed-When: Mon Feb 23 08:57:25 PST 2004 
Responsible-Changed-Why:  
VMware developer points out that there is a race condition in lnc 
driver.  Paul, I believe you are the best person of investigating 
this problem (the copyright says you're the author).  Would you please 
check this PR out? 

FYI, this problem is now also discussed at VMware Community Forums. 
See also: http://www.vmware.com/community/thread.jspa?threadID=1816&tstart=0 

http://www.freebsd.org/cgi/query-pr.cgi?pr=44126 
State-Changed-From-To: open->closed 
State-Changed-By: paul 
State-Changed-When: Mon May 16 11:12:19 GMT 2005 
State-Changed-Why:  
This is more likely to be a VMWARE bug with emulating the lance hardware. A bug was filed with VMWARE quite a while ago. This is better closed and can be reopened if there are still issued with more current versions of both FreeBSD and VMWARE. 

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