diff --git a/sys/sparc64/include/pv.h b/sys/sparc64/include/pv.h index 732ef03e6f32..96b2b89939f3 100644 --- a/sys/sparc64/include/pv.h +++ b/sys/sparc64/include/pv.h @@ -40,8 +40,7 @@ #ifndef _MACHINE_PV_H_ #define _MACHINE_PV_H_ -extern vm_zone_t pvzone; -extern struct vm_zone pvzone_store; +extern uma_zone_t pvzone; extern struct vm_object pvzone_obj; extern int pv_entry_count; extern int pv_entry_max; diff --git a/sys/sparc64/sparc64/genassym.c b/sys/sparc64/sparc64/genassym.c index 055a96c1080b..6791f4e073b6 100644 --- a/sys/sparc64/sparc64/genassym.c +++ b/sys/sparc64/sparc64/genassym.c @@ -46,7 +46,6 @@ #include #include #include -#include #include #include diff --git a/sys/sparc64/sparc64/pmap.c b/sys/sparc64/sparc64/pmap.c index 33238615659a..ad425b3b5963 100644 --- a/sys/sparc64/sparc64/pmap.c +++ b/sys/sparc64/sparc64/pmap.c @@ -89,7 +89,7 @@ #include #include #include -#include +#include #include #include @@ -543,17 +543,10 @@ pmap_init(vm_offset_t phys_start, vm_offset_t phys_end) panic("pmap_init: vm_map_find"); } -#if 0 - pvzone = &pvzone_store; - pvinit = (struct pv_entry *)kmem_alloc(kernel_map, - vm_page_array_size * sizeof (struct pv_entry)); - zbootinit(pvzone, "PV ENTRY", sizeof (struct pv_entry), pvinit, - vm_page_array_size); -#else - pvzone = zinit("PV ENTRY", sizeof (struct pv_entry), 0, 0, 0); + pvzone = uma_zcreate("PV ENTRY", sizeof (struct pv_entry), + NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, 0); uma_zone_set_allocf(pvzone, pv_allocf); uma_prealloc(pvzone, vm_page_array_size); -#endif pmap_initialized = TRUE; } @@ -571,11 +564,7 @@ pmap_init2(void) TUNABLE_INT_FETCH("vm.pmap.shpgperproc", &shpgperproc); pv_entry_max = shpgperproc * maxproc + vm_page_array_size; pv_entry_high_water = 9 * (pv_entry_max / 10); -#if 0 - zinitna(pvzone, &pvzone_obj, NULL, 0, pv_entry_max, ZONE_INTERRUPT, 1); -#else uma_zone_set_obj(pvzone, &pvzone_obj, pv_entry_max); -#endif } /* diff --git a/sys/sparc64/sparc64/pv.c b/sys/sparc64/sparc64/pv.c index 1b3b2edf6bbe..990a76b85b62 100644 --- a/sys/sparc64/sparc64/pv.c +++ b/sys/sparc64/sparc64/pv.c @@ -49,7 +49,7 @@ #include #include #include -#include +#include #include #include @@ -60,10 +60,7 @@ #include #include -vm_zone_t pvzone; -#if 0 -struct vm_zone pvzone_store; -#endif +uma_zone_t pvzone; struct vm_object pvzone_obj; int pv_entry_count; int pv_entry_max; @@ -80,7 +77,7 @@ pv_alloc(void) pmap_pagedaemon_waken = 1; wakeup(&vm_pages_needed); } - return (zalloc(pvzone)); + return (uma_zalloc(pvzone), M_WAITOK); } void * @@ -96,7 +93,7 @@ pv_free(pv_entry_t pv) { pv_entry_count--; - zfree(pvzone, pv); + uma_zfree(pvzone, pv); } /* diff --git a/sys/sparc64/sparc64/trap.c b/sys/sparc64/sparc64/trap.c index f2eeaa6ae093..37429bcda0ec 100644 --- a/sys/sparc64/sparc64/trap.c +++ b/sys/sparc64/sparc64/trap.c @@ -65,7 +65,6 @@ #include #include #include -#include #include #include diff --git a/sys/sparc64/sparc64/tsb.c b/sys/sparc64/sparc64/tsb.c index 959ab8561ac3..1132df318569 100644 --- a/sys/sparc64/sparc64/tsb.c +++ b/sys/sparc64/sparc64/tsb.c @@ -52,7 +52,6 @@ #include #include #include -#include #include #include