From owner-freebsd-current@FreeBSD.ORG Fri Nov 13 19:40:57 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 817EF106568D for ; Fri, 13 Nov 2009 19:40:57 +0000 (UTC) (envelope-from cswiger@mac.com) Received: from asmtpout015.mac.com (asmtpout015.mac.com [17.148.16.90]) by mx1.freebsd.org (Postfix) with ESMTP id 6F7048FC1F for ; Fri, 13 Nov 2009 19:40:57 +0000 (UTC) MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Received: from cswiger1.apple.com ([17.227.140.124]) by asmtp015.mac.com (Sun Java(tm) System Messaging Server 6.3-8.01 (built Dec 16 2008; 32bit)) with ESMTPSA id <0KT200DVNBZWL260@asmtp015.mac.com> for current@freebsd.org; Fri, 13 Nov 2009 11:40:46 -0800 (PST) Message-id: From: Chuck Swiger To: Ben Kelly In-reply-to: <75C5C3A9-E8B7-4EBB-8731-603981BADD97@wanderview.com> Date: Fri, 13 Nov 2009 11:40:44 -0800 References: <75C5C3A9-E8B7-4EBB-8731-603981BADD97@wanderview.com> X-Mailer: Apple Mail (2.936) Cc: current@freebsd.org Subject: Re: dummynet log messages after recent update X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Nov 2009 19:40:57 -0000 Hi, Ben-- On Nov 13, 2009, at 10:43 AM, Ben Kelly wrote: > I recently upgraded my firewall from a soekris net4501 to a > net5501. As part of this process I update my freebsd sources to > CURRENT as of 11/13/2009 1300 GMT. Once the new box was up and > running I noticed some odd output in the logs: > > Nov 13 18:30:19 gate kernel: dummynet: OUCH! pipe should have been > idle! > Nov 13 18:30:34 gate last message repeated 15 times The message is coming from netinet/ip_dummynet.c: /* * Look at eligibility. A flow is not eligibile if S>V (when * this happens, it means that there is some other flow already * scheduled for the same pipe, so the scheduler_heap cannot be * empty). If the flow is not eligible we just store it in the * not_eligible_heap. Otherwise, we store in the scheduler_heap * and possibly invoke ready_event_wfq() right now if there is * leftover credit. * Note that for all flows in scheduler_heap (SCH), S_i <= V, * and for all flows in not_eligible_heap (NEH), S_i > V. * So when we need to compute max(V, min(S_i)) forall i in * SCH+NEH, we only need to look into NEH. */ if (DN_KEY_GT(q->S, pipe->V)) { /* Not eligible. */ if (pipe->scheduler_heap.elements == 0) printf("dummynet: ++ ouch! not eligible but empty scheduler!\n"); heap_insert(&(pipe->not_eligible_heap), q->S, q); } else { heap_insert(&(pipe->scheduler_heap), q->F, q); if (pipe->numbytes >= 0) { /* Pipe is idle. */ if (pipe->scheduler_heap.elements != 1) printf("dummynet: OUCH! pipe should have been idle!\n"); DPRINTF(("dummynet: waking up pipe %d at %d\n", pipe->pipe_nr, (int)(q->F >> MY_M))); pipe->sched_time = curr_time; ready_event_wfq(pipe, &head, &tail); } } I'm not entirely sure of logic in the /* Pipe is idle. */ test is right-- if pipe->numbytes == 0, I'd agree the pipe is idle, but if you have some bytes of traffic in the pipe, the the assumption that the current packet is the only traffic doesn't seem to make sense. But, I'm not the author of the code.... :-) Regards, -- -Chuck