use the -newos toolchain even if -elf is present.
[newos.git] / include / kernel / vm_cache.h
blob71a86772adadf696c5601709eb95412503f38ddf
1 /*
2 ** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved.
3 ** Distributed under the terms of the NewOS License.
4 */
5 #ifndef _KERNEL_VM_CACHE_H
6 #define _KERNEL_VM_CACHE_H
8 #include <kernel/kernel.h>
9 #include <kernel/vm.h>
10 #include <boot/stage2.h>
12 int vm_cache_init(kernel_args *ka);
13 vm_cache *vm_cache_create(vm_store *store);
14 vm_cache_ref *vm_cache_ref_create(vm_cache *cache);
15 void vm_cache_acquire_ref(vm_cache_ref *cache_ref, bool acquire_store_ref);
16 void vm_cache_release_ref(vm_cache_ref *cache_ref);
17 vm_page *vm_cache_lookup_page(vm_cache_ref *cache_ref, off_t page);
18 void vm_cache_insert_page(vm_cache_ref *cache_ref, vm_page *page, off_t offset);
19 void vm_cache_remove_page(vm_cache_ref *cache_ref, vm_page *page);
20 int vm_cache_insert_region(vm_cache_ref *cache_ref, vm_region *region);
21 int vm_cache_remove_region(vm_cache_ref *cache_ref, vm_region *region);
23 #endif