[openfirmware] [commit] r2220 - ofw/inet

repository service svn at openfirmware.info
Tue May 24 23:12:46 CEST 2011


Author: wmb
Date: Tue May 24 23:12:36 2011
New Revision: 2220
URL: http://tracker.coreboot.org/trac/openfirmware/changeset/2220

Log:
TCP - Reduced the TCP receive buffer size to keep the advertised window smaller, thus preventing the other end from sending-ahead more data than small-buffer network interfaces can handle.  This makes HTTP reads work much better on OLPC XO-1.5 and 1.75 systems, especially over WLAN.

Modified:
   ofw/inet/tcp.fth

Modified: ofw/inet/tcp.fth
==============================================================================
--- ofw/inet/tcp.fth	Mon May 23 23:06:42 2011	(r2219)
+++ ofw/inet/tcp.fth	Tue May 24 23:12:36 2011	(r2220)
@@ -1955,7 +1955,13 @@
 \ This is basically attach
 : alloc-buffers  ( -- )
    wbuf-allocate
-   d# 1024 d# 16 *  to rbuf-len
+   \ If rbuf-len is too large, the other end can send-ahead more data
+   \ than some network interfaces can handle, leading to very poor
+   \ performance and in some cases complete failure.  Ideally we would
+   \ size this dynamically based on the network interface characteristics
+   \ (speed, buffering), but for now we don't have suitable information
+   \ in the network interface device node.
+   d# 1024 8 *  to rbuf-len
    rbuf-len alloc-mem to rbuf-adr
    0 to rbuf-actual
 



More information about the openfirmware mailing list