o Use the VM_ALLOC_WIRED flag instead of calling vm_page_wire().
This commit is contained in:
parent
38f612e053
commit
fab965bf7e
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=101647
@ -421,13 +421,10 @@ agp_generic_bind_memory(device_t dev, struct agp_memory *mem,
|
||||
* the pages will be allocated and zeroed.
|
||||
*/
|
||||
m = vm_page_grab(mem->am_obj, OFF_TO_IDX(i),
|
||||
VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
VM_ALLOC_WIRED | VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
if ((m->flags & PG_ZERO) == 0)
|
||||
vm_page_zero_fill(m);
|
||||
AGP_DPF("found page pa=%#x\n", VM_PAGE_TO_PHYS(m));
|
||||
vm_page_lock_queues();
|
||||
vm_page_wire(m);
|
||||
vm_page_unlock_queues();
|
||||
|
||||
/*
|
||||
* Install entries in the GATT, making sure that if
|
||||
|
@ -370,11 +370,11 @@ agp_i810_alloc_memory(device_t dev, int type, vm_size_t size)
|
||||
* get its physical address.
|
||||
*/
|
||||
vm_page_t m;
|
||||
m = vm_page_grab(mem->am_obj, 0, VM_ALLOC_ZERO|VM_ALLOC_RETRY);
|
||||
m = vm_page_grab(mem->am_obj, 0,
|
||||
VM_ALLOC_WIRED | VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
if ((m->flags & PG_ZERO) == 0)
|
||||
vm_page_zero_fill(m);
|
||||
vm_page_lock_queues();
|
||||
vm_page_wire(m);
|
||||
mem->am_physical = VM_PAGE_TO_PHYS(m);
|
||||
vm_page_wakeup(m);
|
||||
vm_page_unlock_queues();
|
||||
|
@ -421,13 +421,10 @@ agp_generic_bind_memory(device_t dev, struct agp_memory *mem,
|
||||
* the pages will be allocated and zeroed.
|
||||
*/
|
||||
m = vm_page_grab(mem->am_obj, OFF_TO_IDX(i),
|
||||
VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
VM_ALLOC_WIRED | VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
if ((m->flags & PG_ZERO) == 0)
|
||||
vm_page_zero_fill(m);
|
||||
AGP_DPF("found page pa=%#x\n", VM_PAGE_TO_PHYS(m));
|
||||
vm_page_lock_queues();
|
||||
vm_page_wire(m);
|
||||
vm_page_unlock_queues();
|
||||
|
||||
/*
|
||||
* Install entries in the GATT, making sure that if
|
||||
|
@ -370,11 +370,11 @@ agp_i810_alloc_memory(device_t dev, int type, vm_size_t size)
|
||||
* get its physical address.
|
||||
*/
|
||||
vm_page_t m;
|
||||
m = vm_page_grab(mem->am_obj, 0, VM_ALLOC_ZERO|VM_ALLOC_RETRY);
|
||||
m = vm_page_grab(mem->am_obj, 0,
|
||||
VM_ALLOC_WIRED | VM_ALLOC_ZERO | VM_ALLOC_RETRY);
|
||||
if ((m->flags & PG_ZERO) == 0)
|
||||
vm_page_zero_fill(m);
|
||||
vm_page_lock_queues();
|
||||
vm_page_wire(m);
|
||||
mem->am_physical = VM_PAGE_TO_PHYS(m);
|
||||
vm_page_wakeup(m);
|
||||
vm_page_unlock_queues();
|
||||
|
Loading…
Reference in New Issue
Block a user