ports/105580: bochs ne2k module was broken in FreeBSD

Thinker thinker at branda.to
Wed Nov 15 18:50:03 UTC 2006


>Number:         105580
>Category:       ports
>Synopsis:       bochs ne2k module was broken in FreeBSD
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 15 18:50:01 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     User &
>Release:        FreeBSD 7.0-CURRENT i386
>Organization:
Thinker
>Environment:
System: FreeBSD seeker.branda.to 7.0-CURRENT FreeBSD 7.0-CURRENT #1: Fri
Nov 10 01:50:04 CST 2006
thinker at seeker.branda.to:/usr/src/sys/i386/compile/seeker i386



>Description:
If you use ne2k driver for FreeBSD, bochs will not receive incoming packets
untill the buffer specified by bochs is full (2048). It cause connections
timeout in low traffic condition. Client OS think it losts packets, but it
actually in a BPF buffer waiting for receive.

>How-To-Repeat:
Run bochs on FreeBSD with it's fbsd ne2k module.

>Fix:

apply following patch.


--- patch-iodev::eth_fbsd.cc begins here ---
--- iodev/eth_fbsd.cc.orig Wed Nov 15 23:57:57 2006
+++ iodev/eth_fbsd.cc Wed Nov 15 23:59:04 2006
@@ -227,6 +227,14 @@
return;
}

+ v = 1;
+ if (ioctl(this->bpf_fd, BIOCIMMEDIATE, &v) < 0) {
+ BX_PANIC(("eth_freebsd: could not enable immediate mode"));
+ close(this->bpf_fd);
+ this->bpf_fd = -1;
+ return;
+ }
+
// Set up non-blocking i/o
v = 1;
if (ioctl(this->bpf_fd, FIONBIO, &v) < 0) {
--- patch-iodev::eth_fbsd.cc ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list