Changes in kernel/generic/src/mm/as.c [59fb782:5df1963] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/as.c
r59fb782 r5df1963 488 488 489 489 /* Eventually check the addresses behind each area */ 490 list_foreach(as->as_area_btree.leaf_list, cur) { 491 btree_node_t *node = 492 list_get_instance(cur, btree_node_t, leaf_link); 490 list_foreach(as->as_area_btree.leaf_list, leaf_link, btree_node_t, node) { 493 491 494 492 for (btree_key_t i = 0; i < node->keys; i++) { … … 904 902 * reference from all frames found there. 905 903 */ 906 list_foreach(sh_info->pagemap.leaf_list, cur) { 907 btree_node_t *node 908 = list_get_instance(cur, btree_node_t, leaf_link); 904 list_foreach(sh_info->pagemap.leaf_list, leaf_link, 905 btree_node_t, node) { 909 906 btree_key_t i; 910 907 911 908 for (i = 0; i < node->keys; i++) 912 frame_free((uintptr_t) node->value[i] );909 frame_free((uintptr_t) node->value[i], 1); 913 910 } 914 911 … … 956 953 * Visit only the pages mapped by used_space B+tree. 957 954 */ 958 list_foreach(area->used_space.leaf_list, cur) {959 btree_node_t *node;955 list_foreach(area->used_space.leaf_list, leaf_link, btree_node_t, 956 node) { 960 957 btree_key_t i; 961 958 962 node = list_get_instance(cur, btree_node_t, leaf_link);963 959 for (i = 0; i < node->keys; i++) { 964 960 uintptr_t ptr = node->key[i]; … … 1238 1234 size_t used_pages = 0; 1239 1235 1240 list_foreach(area->used_space.leaf_list, cur) { 1241 btree_node_t *node 1242 = list_get_instance(cur, btree_node_t, leaf_link); 1236 list_foreach(area->used_space.leaf_list, leaf_link, btree_node_t, 1237 node) { 1243 1238 btree_key_t i; 1244 1239 … … 1264 1259 size_t frame_idx = 0; 1265 1260 1266 list_foreach(area->used_space.leaf_list, cur) { 1267 btree_node_t *node = list_get_instance(cur, btree_node_t, 1268 leaf_link); 1261 list_foreach(area->used_space.leaf_list, leaf_link, btree_node_t, 1262 node) { 1269 1263 btree_key_t i; 1270 1264 … … 1316 1310 frame_idx = 0; 1317 1311 1318 list_foreach(area->used_space.leaf_list, cur) { 1319 btree_node_t *node 1320 = list_get_instance(cur, btree_node_t, leaf_link); 1312 list_foreach(area->used_space.leaf_list, leaf_link, btree_node_t, 1313 node) { 1321 1314 btree_key_t i; 1322 1315 … … 2182 2175 size_t area_cnt = 0; 2183 2176 2184 list_foreach(as->as_area_btree.leaf_list, cur) { 2185 btree_node_t *node = 2186 list_get_instance(cur, btree_node_t, leaf_link); 2177 list_foreach(as->as_area_btree.leaf_list, leaf_link, btree_node_t, 2178 node) { 2187 2179 area_cnt += node->keys; 2188 2180 } … … 2195 2187 size_t area_idx = 0; 2196 2188 2197 list_foreach(as->as_area_btree.leaf_list, cur) { 2198 btree_node_t *node = 2199 list_get_instance(cur, btree_node_t, leaf_link); 2189 list_foreach(as->as_area_btree.leaf_list, leaf_link, btree_node_t, 2190 node) { 2200 2191 btree_key_t i; 2201 2192 … … 2231 2222 2232 2223 /* Print out info about address space areas */ 2233 list_foreach(as->as_area_btree.leaf_list, cur) { 2234 btree_node_t *node 2235 = list_get_instance(cur, btree_node_t, leaf_link); 2224 list_foreach(as->as_area_btree.leaf_list, leaf_link, btree_node_t, 2225 node) { 2236 2226 btree_key_t i; 2237 2227
Note:
See TracChangeset
for help on using the changeset viewer.