summaryrefslogtreecommitdiff
path: root/include/linux/writeback.h
diff options
context:
space:
mode:
authorAndi Kleen <ak@suse.de>2005-03-04 01:15:48 +0100
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-03-04 01:15:48 +0100
commit08a3c0c0d07a568330b9033d5f43cece3495f8da (patch)
tree78e2305005cd470555402e151dc714a4ea554711 /include/linux/writeback.h
parent33ef19f6fb1c9217eea2993c54999347c47c51bf (diff)
[NETFILTER]: Reduce netfilter memory use on MP systems
On kernels compiled with a big NR_CPUS netfilter rules would eat a lot of memory because all counters would be duplicated for all NR_CPUs CPUs. With NR_CPUS=256 this would add up to many MBs of memory. This patch only allocates enough memory for the possible CPUs, which is usually a much smaller number than NR_CPUS. This allows loading of bigger rule sets on 64bit systems. There is still a limit because someone else broke vmalloc to have a 64MB limit on 64bit systems for single allocations, 129MB on 32bit. It allocates an array of pages with kmalloc and kmalloc has a 128K limit. To be fixed with a separate patch. 64bit systems were hurt worst because they tend to have big NR_CPUS and the counters need more memory there, and the vmalloc limit is lower. But it will raise the limits even on 32bit. And in general it saves a lot of memory. Tested only on a small dual CPU box. Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'include/linux/writeback.h')
0 files changed, 0 insertions, 0 deletions