Changeset bfb1179 in mainline
- Timestamp:
- 2018-12-10T10:50:30Z (6 years ago)
- Parents:
- dd74b5b
- git-author:
- Jiri Svoboda <jiri@…> (2018-12-10 07:33:08)
- git-committer:
- Jiri Svoboda <jiri@…> (2018-12-10 10:50:30)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/as.c
rdd74b5b rbfb1179 1390 1390 mutex_unlock(&area->sh_info->lock); 1391 1391 1392 /*1393 * Compute total number of used pages1394 */1395 size_t used_pages = 0;1396 1397 used_space_ival_t *ival = used_space_first(&area->used_space);1398 while (ival != NULL) {1399 used_pages += ival->count;1400 ival = used_space_next(ival);1401 }1402 1403 1392 /* An array for storing frame numbers */ 1404 uintptr_t *old_frame = malloc(used_pages * sizeof(uintptr_t)); 1393 uintptr_t *old_frame = malloc(area->used_space.pages * 1394 sizeof(uintptr_t)); 1405 1395 if (!old_frame) { 1406 1396 mutex_unlock(&area->lock); … … 1423 1413 size_t frame_idx = 0; 1424 1414 1425 ival = used_space_first(&area->used_space);1415 used_space_ival_t *ival = used_space_first(&area->used_space); 1426 1416 while (ival != NULL) { 1427 1417 uintptr_t ptr = ival->page;
Note:
See TracChangeset
for help on using the changeset viewer.