From owner-freebsd-bugs Sat Jan 22 0:50: 5 2000 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id E40FD15026 for ; Sat, 22 Jan 2000 00:50:02 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id AAA68439; Sat, 22 Jan 2000 00:50:02 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: by hub.freebsd.org (Postfix, from userid 32767) id E65EE15558; Sat, 22 Jan 2000 00:42:27 -0800 (PST) Message-Id: <20000122084227.E65EE15558@hub.freebsd.org> Date: Sat, 22 Jan 2000 00:42:27 -0800 (PST) From: hide@koie.org To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-1.0 Subject: kern/16292: performance problem of divert socket Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 16292 >Category: kern >Synopsis: performance problem of divert socket >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Jan 22 00:50:01 PST 2000 >Closed-Date: >Last-Modified: >Originator: KOIE Hidetaka >Release: FreeBSD 3.3-RELEASE >Organization: >Environment: FreeBSD skipjack.koie.org 3.3-RELEASE FreeBSD 3.3-RELEASE #0: Wed Dec 8 09:16:43 JST 1999 koie@skipjack.koie.org:/usr/src/sys/compile/TP i386 >Description: In sys/netinet/ip_output.c, ip_output() checks that ifnet::if_snd has room enough to enqueue entire packet. This verifying code is commited at revision 1.3. But, using divert socket and IPFW, on fire hose syndrome router, user-land program (ipfw add divert N ... out xmit IFACE) can not receive all packets. /* * Verify that we have any chance at all of being able to queue * the packet or packet fragments */ if ((ifp->if_snd.ifq_len + ip->ip_len / ifp->if_mtu + 1) >= ifp->if_snd.ifq_maxlen) { error = ENOBUFS; goto bad; } >How-To-Repeat: >Fix: IMHO, this verifing code should be moved to the immediately following `pass:'. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message