Changes in kernel/generic/src/mm/page.c [d4673296:8757be86] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/page.c
rd4673296 r8757be86 84 84 } 85 85 86 /** Map memory structure87 *88 * Identity-map memory structure89 * considering possible crossings90 * of page boundaries.91 *92 * @param addr Address of the structure.93 * @param size Size of the structure.94 *95 */96 void map_structure(uintptr_t addr, size_t size)97 {98 size_t length = size + (addr - (addr & ~(PAGE_SIZE - 1)));99 size_t cnt = length / PAGE_SIZE + (length % PAGE_SIZE > 0);100 101 size_t i;102 for (i = 0; i < cnt; i++)103 page_mapping_insert(AS_KERNEL, addr + i * PAGE_SIZE,104 addr + i * PAGE_SIZE, PAGE_NOT_CACHEABLE | PAGE_WRITE);105 106 /* Repel prefetched accesses to the old mapping. */107 memory_barrier();108 }109 110 86 /** Insert mapping of page to frame. 111 87 *
Note:
See TracChangeset
for help on using the changeset viewer.