David Miller wrote: > From: John Heffner > Date: Wed, 14 Mar 2007 17:25:22 -0400 > >> The current tcp_mem initialization gives values that are really too >> small for systems with ~256-768 MB of memory, and also for systems with >> larger page sizes (ia64). This patch gives an alternate method of >> initialization that doesn't depend on the cache allocation functions, >> but I think should still provide a nice curve that gives a smaller >> fraction of total memory with small-memory systems, while maintaining >> the same upper bound (pressure at 1/2, max as 3/4) on larger memory systems. > > Indeed, it's really dumb for any of these calculations to be > dependant upon the page size. > > Your patch looks good, and I'll review it further tomorrow and > push upstream unless I find some issues with it. > > Thanks John. The way it's coded is somewhat opaque since it has to be done with 32-bit integer arithmetic. These plots might help make the motivation behind the code a little clearer. Thanks, -John