Changes in kernel/generic/src/mm/as.c [e394b736:30718cc2] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/as.c
re394b736 r30718cc2 80 80 #include <arch/interrupt.h> 81 81 82 #ifdef CONFIG_VIRT_IDX_DCACHE 83 #include <arch/mm/cache.h> 84 #endif /* CONFIG_VIRT_IDX_DCACHE */ 85 82 86 /** 83 87 * Each architecture decides what functions will be used to carry out … … 443 447 else 444 448 memsetb(&area->backend_data, sizeof(area->backend_data), 0); 445 446 if (area->backend && area->backend->create) {447 if (!area->backend->create(area)) {448 free(area);449 mutex_unlock(&as->lock);450 return NULL;451 }452 }453 449 454 450 btree_create(&area->used_space); … … 694 690 } 695 691 696 if (area->backend && area->backend->resize) {697 if (!area->backend->resize(area, pages)) {698 mutex_unlock(&area->lock);699 mutex_unlock(&as->lock);700 return ENOMEM;701 }702 }703 704 692 area->pages = pages; 705 693 … … 768 756 return ENOENT; 769 757 } 770 771 if (area->backend && area->backend->destroy)772 area->backend->destroy(area);773 758 774 759 uintptr_t base = area->base; … … 1964 1949 sysarg_t sys_as_area_create(uintptr_t address, size_t size, unsigned int flags) 1965 1950 { 1966 if (as_area_create(AS, flags | AS_AREA_CACHEABLE, size, address,1951 if (as_area_create(AS, flags, size, address, 1967 1952 AS_AREA_ATTR_NONE, &anon_backend, NULL)) 1968 1953 return (sysarg_t) address;
Note:
See TracChangeset
for help on using the changeset viewer.