Changeset 88dea9d in mainline for kernel/generic/src/mm/frame.c
- Timestamp:
- 2010-04-17T16:28:49Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 30a5470
- Parents:
- 5ba201d (diff), 95319bd (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/frame.c
r5ba201d r88dea9d 1218 1218 } 1219 1219 1220 void zone_busy_and_free(uint64_t *out_busy, uint64_t *out_free) 1221 { 1222 ipl_t ipl = interrupts_disable(); 1223 spinlock_lock(&zones.lock); 1224 1225 uint64_t busy = 0, free = 0; 1226 size_t i; 1227 for (i = 0; i < zones.count; i++) { 1228 bool available = zone_flags_available(zones.info[i].flags); 1229 /* Do not count reserved memory */ 1230 if (available) { 1231 busy += (uint64_t) FRAMES2SIZE(zones.info[i].busy_count); 1232 free += (uint64_t) FRAMES2SIZE(zones.info[i].free_count); 1233 } 1234 } 1235 1236 spinlock_unlock(&zones.lock); 1237 interrupts_restore(ipl); 1238 *out_busy = busy; 1239 *out_free = free; 1240 } 1241 1220 1242 /** Prints list of zones. */ 1221 1243 void zone_print_list(void)
Note:
See TracChangeset
for help on using the changeset viewer.