Date: Sat, 5 Feb 2011 23:32:17 +0000 (UTC) From: Luigi Rizzo <luigi@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r218360 - head/sys/netinet/ipfw Message-ID: <201102052332.p15NWHHE045225@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: luigi Date: Sat Feb 5 23:32:17 2011 New Revision: 218360 URL: http://svn.freebsd.org/changeset/base/218360 Log: correct the 'output_time' of packets generated by dummynet. In the dec.2009 rewrite I introduced a bug, using for the computation the arrival time instead of the time the packet has exited from the queue. The bandwidth computation was still correct because it is computed elsewhere, but traffic was sent out in bursts. The bug is also present in RELENG_8 after dec.2009 Thanks to Daikichi Osuga for investingating, finding and fixing the bug with detailed graphs of the behaviour before and after the fix. Submitted by: Daikichi Osuga MFC after: 2 weeks Modified: head/sys/netinet/ipfw/ip_dn_io.c Modified: head/sys/netinet/ipfw/ip_dn_io.c ============================================================================== --- head/sys/netinet/ipfw/ip_dn_io.c Sat Feb 5 23:03:40 2011 (r218359) +++ head/sys/netinet/ipfw/ip_dn_io.c Sat Feb 5 23:32:17 2011 (r218360) @@ -471,7 +471,7 @@ serve_sched(struct mq *q, struct dn_sch_ (m->m_pkthdr.len * 8 + extra_bits(m, s)); si->credit -= len_scaled; /* Move packet in the delay line */ - dn_tag_get(m)->output_time += s->link.delay ; + dn_tag_get(m)->output_time = dn_cfg.curr_time + s->link.delay ; mq_append(&si->dline.mq, m); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201102052332.p15NWHHE045225>