Changes in kernel/generic/src/mm/backend_phys.c [cda1378:a0ce870] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/backend_phys.c
rcda1378 ra0ce870 48 48 #include <align.h> 49 49 50 static bool phys_create(as_area_t *); 51 static void phys_share(as_area_t *); 52 static void phys_destroy(as_area_t *); 53 54 static int phys_page_fault(as_area_t *, uintptr_t, pf_access_t); 50 static int phys_page_fault(as_area_t *area, uintptr_t addr, pf_access_t access); 51 static void phys_share(as_area_t *area); 55 52 56 53 mem_backend_t phys_backend = { 57 .create = phys_create,58 .resize = NULL,59 .share = phys_share,60 .destroy = phys_destroy,61 62 54 .page_fault = phys_page_fault, 63 55 .frame_free = NULL, 56 .share = phys_share 64 57 }; 65 66 bool phys_create(as_area_t *area)67 {68 return true;69 }70 71 /** Share address space area backed by physical memory.72 *73 * Do actually nothing as sharing of address space areas74 * that are backed up by physical memory is very easy.75 * Note that the function must be defined so that76 * as_area_share() will succeed.77 */78 void phys_share(as_area_t *area)79 {80 ASSERT(mutex_locked(&area->as->lock));81 ASSERT(mutex_locked(&area->lock));82 }83 84 85 void phys_destroy(as_area_t *area)86 {87 /* Nothing to do. */88 }89 58 90 59 /** Service a page fault in the address space area backed by physical memory. … … 119 88 } 120 89 90 /** Share address space area backed by physical memory. 91 * 92 * Do actually nothing as sharing of address space areas 93 * that are backed up by physical memory is very easy. 94 * Note that the function must be defined so that 95 * as_area_share() will succeed. 96 */ 97 void phys_share(as_area_t *area) 98 { 99 ASSERT(mutex_locked(&area->as->lock)); 100 ASSERT(mutex_locked(&area->lock)); 101 } 102 121 103 /** @} 122 104 */
Note:
See TracChangeset
for help on using the changeset viewer.