diff options
author | Richard Braun <rbraun@sceen.net> | 2016-09-20 22:59:42 +0200 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2016-09-21 00:21:08 +0200 |
commit | 783ad37f65384994dfa5387ab3847a8a4d77b90b (patch) | |
tree | b79f445a9fe53680cca9484fc3e02a32d6859e5c /xen | |
parent | 38aca37c00548f9b31bf17e74ab4a36c73521782 (diff) | |
download | gnumach-783ad37f65384994dfa5387ab3847a8a4d77b90b.tar.gz gnumach-783ad37f65384994dfa5387ab3847a8a4d77b90b.tar.bz2 gnumach-783ad37f65384994dfa5387ab3847a8a4d77b90b.zip |
Redefine what an external page is
Instead of a "page considered external", which apparently takes into
account whether a page is dirty or not, redefine this property to
reliably mean "is in an external object".
This commit mostly deals with the impact of this change on the page
allocation interface.
* i386/intel/pmap.c (pmap_page_table_page_alloc): Update call to
vm_page_grab.
* kern/slab.c (kmem_pagealloc_physmem): Use vm_page_grab instead of
vm_page_grab_contig.
(kmem_pagefree_physmem): Use vm_page_release instead of
vm_page_free_contig.
* linux/dev/glue/block.c (alloc_buffer, device_read): Update call
to vm_page_grab.
* vm/vm_fault.c (vm_fault_page): Update calls to vm_page_grab and
vm_page_convert.
* vm/vm_map.c (vm_map_copy_steal_pages): Update call to vm_page_grab.
* vm/vm_page.h (struct vm_page): Remove `extcounted' member.
(vm_page_external_limit, vm_page_external_count): Remove extern
declarations.
(vm_page_convert, vm_page_grab): Update declarations.
(vm_page_release, vm_page_grab_phys_addr): New function declarations.
* vm/vm_pageout.c (VM_PAGE_EXTERNAL_LIMIT): Remove macro.
(VM_PAGE_EXTERNAL_TARGET): Likewise.
(vm_page_external_target): Remove variable.
(vm_pageout_scan): Remove specific handling of external pages.
(vm_pageout): Don't set vm_page_external_limit and
vm_page_external_target.
* vm/vm_resident.c (vm_page_external_limit): Remove variable.
(vm_page_insert, vm_page_replace, vm_page_remove): Update external
page tracking.
(vm_page_convert): RemoveĀ `external' parameter.
(vm_page_grab): Likewise. Remove specific handling of external pages.
(vm_page_grab_phys_addr): Update call to vm_page_grab.
(vm_page_release): Remove `external' parameter and remove specific
handling of external pages.
(vm_page_wait): Remove specific handling of external pages.
(vm_page_alloc): Update call to vm_page_grab.
(vm_page_free): Update call to vm_page_release.
* xen/block.c (device_read): Update call to vm_page_grab.
* xen/net.c (device_write): Likewise.
Diffstat (limited to 'xen')
-rw-r--r-- | xen/block.c | 2 | ||||
-rw-r--r-- | xen/net.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/xen/block.c b/xen/block.c index 7d6f1ca3..dc922348 100644 --- a/xen/block.c +++ b/xen/block.c @@ -457,7 +457,7 @@ device_read (void *d, ipc_port_t reply_port, /* Allocate pages. */ while (alloc_offset < offset + len) { - while ((m = vm_page_grab (FALSE)) == 0) + while ((m = vm_page_grab ()) == 0) VM_PAGE_WAIT (0); assert (! m->active && ! m->inactive); m->busy = TRUE; @@ -620,7 +620,7 @@ device_write(void *d, ipc_port_t reply_port, offset = copy->offset & PAGE_MASK; if (paranoia || copy->cpy_npages == 2) { /* have to copy :/ */ - while ((m = vm_page_grab(FALSE)) == 0) + while ((m = vm_page_grab()) == 0) VM_PAGE_WAIT (0); assert (! m->active && ! m->inactive); m->busy = TRUE; |