Make the initial size of the slab depend on the CPU count. This avoids running out of initial space with more than two CPUs. I haven't fully tracked down the usage of this space, probably it is used to allocate some per CPU construct.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23115 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz 2007-12-11 21:54:54 +00:00
parent 9b13056ba2
commit 7ce6a420b7

View File

@ -3477,7 +3477,7 @@ vm_init(kernel_args *args)
vm_low_memory_init();
size_t slabInitialSize = 2 * B_PAGE_SIZE;
size_t slabInitialSize = args->num_cpus * 2 * B_PAGE_SIZE;
addr_t slabInitialBase = vm_allocate_early(args, slabInitialSize,
slabInitialSize, B_KERNEL_READ_AREA | B_KERNEL_WRITE_AREA);
slab_init(args, slabInitialBase, slabInitialSize);