diff options
| author | Attilio Rao <attilio@FreeBSD.org> | 2007-05-31 22:52:15 +0000 |
|---|---|---|
| committer | Attilio Rao <attilio@FreeBSD.org> | 2007-05-31 22:52:15 +0000 |
| commit | 2feb50bf7d6fc45ff13865dd9e480b816e1386a8 (patch) | |
| tree | 10bf0f11ceeb18c6b03947eb85223abbbbf9cc67 /sys/kern/kern_malloc.c | |
| parent | 281660174a65a6ca30cf2079274cc6560357f6ad (diff) | |
Notes
Diffstat (limited to 'sys/kern/kern_malloc.c')
| -rw-r--r-- | sys/kern/kern_malloc.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/kern/kern_malloc.c b/sys/kern/kern_malloc.c index 219d47dcddf1..9a995392a5fb 100644 --- a/sys/kern/kern_malloc.c +++ b/sys/kern/kern_malloc.c @@ -547,7 +547,7 @@ kmeminit(void *dummy) * so make sure that there is enough space. */ vm_kmem_size = VM_KMEM_SIZE + nmbclusters * PAGE_SIZE; - mem_size = VMCNT_GET(page_count); + mem_size = cnt.v_page_count; #if defined(VM_KMEM_SIZE_SCALE) vm_kmem_size_scale = VM_KMEM_SIZE_SCALE; @@ -585,8 +585,8 @@ kmeminit(void *dummy) * to something sane. Be careful to not overflow the 32bit * ints while doing the check. */ - if (((vm_kmem_size / 2) / PAGE_SIZE) > VMCNT_GET(page_count)) - vm_kmem_size = 2 * VMCNT_GET(page_count) * PAGE_SIZE; + if (((vm_kmem_size / 2) / PAGE_SIZE) > cnt.v_page_count) + vm_kmem_size = 2 * cnt.v_page_count * PAGE_SIZE; /* * Tune settings based on the kernel map's size at this time. @@ -646,8 +646,7 @@ malloc_init(void *data) struct malloc_type_internal *mtip; struct malloc_type *mtp; - KASSERT(VMCNT_GET(page_count) != 0, - ("malloc_register before vm_init")); + KASSERT(cnt.v_page_count != 0, ("malloc_register before vm_init")); mtp = data; mtip = uma_zalloc(mt_zone, M_WAITOK | M_ZERO); |
