Changeset 99c2c69e in mainline for kernel/generic/src/mm/km.c
- Timestamp:
- 2013-09-13T00:36:30Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 67fbd5e
- Parents:
- 7f84430 (diff), 11d41be5 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/km.c
r7f84430 r99c2c69e 239 239 uintptr_t km_temporary_page_get(uintptr_t *framep, frame_flags_t flags) 240 240 { 241 uintptr_t frame;242 uintptr_t page;243 244 241 ASSERT(THREAD); 245 242 ASSERT(framep); 246 243 ASSERT(!(flags & ~(FRAME_NO_RESERVE | FRAME_ATOMIC))); 247 244 248 245 /* 249 246 * Allocate a frame, preferably from high memory. 250 247 */ 251 frame = (uintptr_t) frame_alloc(ONE_FRAME, 252 FRAME_HIGHMEM | FRAME_ATOMIC | flags); 248 uintptr_t page; 249 uintptr_t frame = 250 frame_alloc(1, FRAME_HIGHMEM | FRAME_ATOMIC | flags, 0); 253 251 if (frame) { 254 252 page = km_map(frame, PAGE_SIZE, 255 253 PAGE_READ | PAGE_WRITE | PAGE_CACHEABLE); 256 ASSERT(page); // FIXME 254 255 // FIXME 256 ASSERT(page); 257 257 } else { 258 frame = (uintptr_t) frame_alloc(ONE_FRAME, 259 FRAME_LOWMEM | flags); 258 frame = frame_alloc(1, FRAME_LOWMEM | flags, 0); 260 259 if (!frame) 261 260 return (uintptr_t) NULL; 261 262 262 page = PA2KA(frame); 263 263 } 264 264 265 265 *framep = frame; 266 return page; 266 return page; 267 267 } 268 268
Note:
See TracChangeset
for help on using the changeset viewer.