1 /* 2 * Copyright 2019 Haiku, Inc. All Rights Reserved. 3 * Distributed under the terms of the MIT License. 4 */ 5 #include <KernelExport.h> 6 7 #include <boot/kernel_args.h> 8 #include <kernel.h> 9 10 #include <arch/vm.h> 11 #include <vm/vm.h> 12 #include <vm/vm_types.h> 13 14 15 status_t 16 arch_vm_init(kernel_args* args) 17 { 18 dprintf("arch_vm_init\n"); 19 return B_OK; 20 } 21 22 23 status_t 24 arch_vm_init2(kernel_args* args) 25 { 26 dprintf("arch_vm_init2\n"); 27 return B_OK; 28 } 29 30 31 status_t 32 arch_vm_init_post_area(kernel_args* args) 33 { 34 dprintf("arch_vm_init_post_area\n"); 35 return B_OK; 36 } 37 38 39 status_t 40 arch_vm_init_end(kernel_args* args) 41 { 42 dprintf("arch_vm_init_end\n"); 43 return B_OK; 44 } 45 46 47 status_t 48 arch_vm_init_post_modules(kernel_args* args) 49 { 50 dprintf("arch_vm_init_post_modules\n"); 51 return B_OK; 52 } 53 54 55 void 56 arch_vm_aspace_swap(struct VMAddressSpace* from, struct VMAddressSpace* to) 57 { 58 dprintf("arch_vm_aspace_swap\n"); 59 } 60 61 62 bool 63 arch_vm_supports_protection(uint32 protection) 64 { 65 // User-RO/Kernel-RW is not possible 66 if ((protection & B_READ_AREA) != 0 && (protection & B_WRITE_AREA) == 0 67 && (protection & B_KERNEL_WRITE_AREA) != 0) { 68 return false; 69 } 70 71 return true; 72 } 73 74 75 void 76 arch_vm_unset_memory_type(VMArea* area) 77 { 78 } 79 80 81 status_t 82 arch_vm_set_memory_type(VMArea* area, phys_addr_t physicalBase, uint32 type) 83 { 84 return B_OK; 85 } 86