- size_used = round_page(actual * sizeof(vm_offset_t));
- (void) vm_map_wire(ipc_kernel_map, vm_map_trunc_page(addr),
- vm_map_round_page(addr + size),
- VM_PROT_READ|VM_PROT_WRITE, FALSE);
+ size_used = vm_map_round_page(actual * sizeof(vm_offset_t),
+ VM_MAP_PAGE_MASK(ipc_kernel_map));
+ (void) vm_map_wire(
+ ipc_kernel_map,
+ vm_map_trunc_page(addr,
+ VM_MAP_PAGE_MASK(ipc_kernel_map)),
+ vm_map_round_page(addr + size,
+ VM_MAP_PAGE_MASK(ipc_kernel_map)),
+ VM_PROT_READ|VM_PROT_WRITE,
+ FALSE);