From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-22-ewr.dyndns.com (mxout-066-ewr.mailhop.org [216.146.33.66]) by lists.bufferbloat.net (Postfix) with ESMTP id 4BE1B2E0226 for ; Wed, 16 Feb 2011 19:31:13 -0800 (PST) Received: from scan-21-ewr.mailhop.org (scan-21-ewr.local [10.0.141.243]) by mail-22-ewr.dyndns.com (Postfix) with ESMTP id A8A9D30DC7 for ; Thu, 17 Feb 2011 03:31:12 +0000 (UTC) X-Spam-Score: 0.0 () X-Mail-Handler: MailHop by DynDNS X-Originating-IP: 208.74.158.172 Received: from ns3.lanforge.com (mail.candelatech.com [208.74.158.172]) by mail-22-ewr.dyndns.com (Postfix) with ESMTP id 859C831466 for ; Thu, 17 Feb 2011 03:31:08 +0000 (UTC) Received: from [71.112.48.101] (pool-71-112-48-101.sttlwa.dsl-w.verizon.net [71.112.48.101]) (authenticated bits=0) by ns3.lanforge.com (8.14.2/8.14.2) with ESMTP id p1H3V5cW008437 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 16 Feb 2011 19:31:06 -0800 Message-ID: <4D5C9679.3060700@candelatech.com> Date: Wed, 16 Feb 2011 19:31:05 -0800 From: Ben Greear Organization: Candela Technologies User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc13 Thunderbird/3.1.7 MIME-Version: 1.0 To: "John W. Linville" Subject: Re: [RFC] mac80211: implement eBDP algorithm to fight bufferbloat References: <1297619803-2832-1-git-send-email-njs@pobox.com> <1297907356-3214-1-git-send-email-linville@tuxdriver.com> In-Reply-To: <1297907356-3214-1-git-send-email-linville@tuxdriver.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Wed, 16 Feb 2011 19:48:02 -0800 Cc: bloat-devel@lists.bufferbloat.net, johannes@sipsolutions.net, linux-wireless@vger.kernel.org, "Nathaniel J. Smith" X-BeenThere: bloat-devel@lists.bufferbloat.net X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Developers working on AQM, device drivers, and networking stacks" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Feb 2011 03:31:13 -0000 On 02/16/2011 05:49 PM, John W. Linville wrote: > This is an implementation of the eBDP algorithm as documented in > Section IV of "Buffer Sizing for 802.11 Based Networks" by Tianji Li, > et al. > > http://www.hamilton.ie/tianji_li/buffersizing.pdf > > This implementation timestamps an skb before handing it to the hardware > driver, then computes the service time when the transmit status is > reported back from the driver. An exponentially weighted moving > average of per packet service times is used to restrict queueing > delays in hopes of achieving a target packet transmission latency. > > Signed-off-by: John W. Linville > --- > This is preliminary, but it seems to put some limits on latencies > for me. I haven't even really done much testing, so YMMV... > > I'm sure this isn't ideal. This should be combined with the ALT > algorithm to yield the A* algorithm. There are parameters that > probably should be tunable (or at least better researched). This may > not be ideal for 802.11n -- it may even be detrimental to it. > > Still, it is an attempt at addressing buffer bloat. Plus, it should > pertain to all mac80211-based drivers. So, feel free to test it, > suggest different parameters, report real numbers, post patches, > etc... :-) > + /* test for queue admission qualifications */ > + tserv_ns_avg = ewma_read(&sdata->tserv_ns_avg); > + /* constants 2 msec and offset 5 should be tunable? */ > + max_enqueued = 2 * NSEC_PER_MSEC / tserv_ns_avg + 5; > + if (atomic_read(&sdata->enqueued)> max_enqueued) { > + /* silently drop */ > + dev_kfree_skb(skb); > + return IEEE80211_TX_OK; > + } We should have some visible stat to increment when you drop on xmit, tx-fifo error or similar? Thanks, Ben -- Ben Greear Candela Technologies Inc http://www.candelatech.com