Lines Matching refs:node
30 const struct assoc_array_node *node; in assoc_array_subtree_iterate() local
45 node = assoc_array_ptr_to_node(cursor); in assoc_array_subtree_iterate()
58 ptr = ACCESS_ONCE(node->slots[slot]); in assoc_array_subtree_iterate()
88 node = assoc_array_ptr_to_node(cursor); in assoc_array_subtree_iterate()
92 ptr = ACCESS_ONCE(node->slots[slot]); in assoc_array_subtree_iterate()
101 parent = ACCESS_ONCE(node->back_pointer); in assoc_array_subtree_iterate()
102 slot = node->parent_slot; in assoc_array_subtree_iterate()
165 struct assoc_array_node *node; /* Node in which leaf might be found */ member
188 struct assoc_array_node *node; in assoc_array_walk() local
218 node = assoc_array_ptr_to_node(cursor); in assoc_array_walk()
223 ptr = ACCESS_ONCE(node->slots[slot]); in assoc_array_walk()
232 result->terminal_node.node = node; in assoc_array_walk()
324 const struct assoc_array_node *node; in assoc_array_find() local
333 node = result.terminal_node.node; in assoc_array_find()
340 ptr = ACCESS_ONCE(node->slots[slot]); in assoc_array_find()
364 struct assoc_array_node *node; in assoc_array_destroy_subtree() local
391 node = assoc_array_ptr_to_node(cursor); in assoc_array_destroy_subtree()
392 BUG_ON(node->back_pointer != parent); in assoc_array_destroy_subtree()
393 BUG_ON(slot != -1 && node->parent_slot != slot); in assoc_array_destroy_subtree()
397 pr_devel("Node %p [back=%p]\n", node, node->back_pointer); in assoc_array_destroy_subtree()
399 struct assoc_array_ptr *ptr = node->slots[slot]; in assoc_array_destroy_subtree()
414 parent = node->back_pointer; in assoc_array_destroy_subtree()
415 slot = node->parent_slot; in assoc_array_destroy_subtree()
417 kfree(node); in assoc_array_destroy_subtree()
440 node = assoc_array_ptr_to_node(cursor); in assoc_array_destroy_subtree()
497 struct assoc_array_node *node, *new_n0, *new_n1, *side; in assoc_array_insert_into_terminal_node() local
505 node = result->terminal_node.node; in assoc_array_insert_into_terminal_node()
522 ptr = node->slots[i]; in assoc_array_insert_into_terminal_node()
531 edit->leaf_p = &node->slots[i]; in assoc_array_insert_into_terminal_node()
532 edit->dead_leaf = node->slots[i]; in assoc_array_insert_into_terminal_node()
543 edit->leaf_p = &node->slots[free_slot]; in assoc_array_insert_into_terminal_node()
544 edit->adjust_count_on = node; in assoc_array_insert_into_terminal_node()
569 ptr = node->slots[i]; in assoc_array_insert_into_terminal_node()
631 new_n0->back_pointer = node->back_pointer; in assoc_array_insert_into_terminal_node()
632 new_n0->parent_slot = node->parent_slot; in assoc_array_insert_into_terminal_node()
639 new_n0->nr_leaves_on_branch = node->nr_leaves_on_branch; in assoc_array_insert_into_terminal_node()
665 if (assoc_array_ptr_is_meta(node->slots[i])) in assoc_array_insert_into_terminal_node()
666 new_n0->slots[i] = node->slots[i]; in assoc_array_insert_into_terminal_node()
676 if (assoc_array_ptr_is_meta(node->slots[i])) in assoc_array_insert_into_terminal_node()
679 new_n1->slots[next_slot++] = node->slots[i]; in assoc_array_insert_into_terminal_node()
685 new_n0->slots[free_slot] = node->slots[i]; in assoc_array_insert_into_terminal_node()
707 ptr = node->slots[i]; in assoc_array_insert_into_terminal_node()
719 ptr = node->back_pointer; in assoc_array_insert_into_terminal_node()
723 edit->set[0].ptr = &assoc_array_ptr_to_node(ptr)->slots[node->parent_slot]; in assoc_array_insert_into_terminal_node()
726 edit->excised_meta[0] = assoc_array_node_to_ptr(node); in assoc_array_insert_into_terminal_node()
748 int x = ops->diff_objects(assoc_array_ptr_to_leaf(node->slots[i]), in assoc_array_insert_into_terminal_node()
768 new_s0->back_pointer = node->back_pointer; in assoc_array_insert_into_terminal_node()
769 new_s0->parent_slot = node->parent_slot; in assoc_array_insert_into_terminal_node()
794 ptr = node->slots[i]; in assoc_array_insert_into_terminal_node()
815 struct assoc_array_node *node, *new_n0, *side; in assoc_array_insert_mid_shortcut() local
844 node = assoc_array_ptr_to_node(shortcut->back_pointer); in assoc_array_insert_mid_shortcut()
845 edit->set[0].ptr = &node->slots[shortcut->parent_slot]; in assoc_array_insert_mid_shortcut()
1055 struct assoc_array_node *node; member
1073 collapse->node->slots[collapse->slot++] = assoc_array_leaf_to_ptr(leaf); in assoc_array_delete_collapse_iterator()
1102 struct assoc_array_node *node, *new_n0; in assoc_array_delete() local
1123 node = result.terminal_node.node; in assoc_array_delete()
1126 ptr = node->slots[slot]; in assoc_array_delete()
1147 edit->dead_leaf = node->slots[slot]; in assoc_array_delete()
1148 edit->set[0].ptr = &node->slots[slot]; in assoc_array_delete()
1150 edit->adjust_count_on = node; in assoc_array_delete()
1174 if (node->nr_leaves_on_branch <= ASSOC_ARRAY_FAN_OUT + 1) { in assoc_array_delete()
1184 ptr = node->slots[i]; in assoc_array_delete()
1192 node->nr_leaves_on_branch - 1, has_meta); in assoc_array_delete()
1197 parent = node; in assoc_array_delete()
1222 if (has_meta || parent != node) { in assoc_array_delete()
1223 node = parent; in assoc_array_delete()
1231 new_n0->back_pointer = node->back_pointer; in assoc_array_delete()
1232 new_n0->parent_slot = node->parent_slot; in assoc_array_delete()
1233 new_n0->nr_leaves_on_branch = node->nr_leaves_on_branch; in assoc_array_delete()
1236 collapse.node = new_n0; in assoc_array_delete()
1239 assoc_array_subtree_iterate(assoc_array_node_to_ptr(node), in assoc_array_delete()
1240 node->back_pointer, in assoc_array_delete()
1246 if (!node->back_pointer) { in assoc_array_delete()
1248 } else if (assoc_array_ptr_is_leaf(node->back_pointer)) { in assoc_array_delete()
1250 } else if (assoc_array_ptr_is_node(node->back_pointer)) { in assoc_array_delete()
1252 assoc_array_ptr_to_node(node->back_pointer); in assoc_array_delete()
1253 edit->set[1].ptr = &p->slots[node->parent_slot]; in assoc_array_delete()
1254 } else if (assoc_array_ptr_is_shortcut(node->back_pointer)) { in assoc_array_delete()
1256 assoc_array_ptr_to_shortcut(node->back_pointer); in assoc_array_delete()
1260 edit->excised_subtree = assoc_array_node_to_ptr(node); in assoc_array_delete()
1365 struct assoc_array_node *node; in assoc_array_apply_edit() local
1393 node = edit->adjust_count_on; in assoc_array_apply_edit()
1395 node->nr_leaves_on_branch += edit->adjust_count_by; in assoc_array_apply_edit()
1397 ptr = node->back_pointer; in assoc_array_apply_edit()
1407 node = assoc_array_ptr_to_node(ptr); in assoc_array_apply_edit()
1476 struct assoc_array_node *node, *new_n; in assoc_array_gc() local
1524 node = assoc_array_ptr_to_node(cursor); in assoc_array_gc()
1528 pr_devel("dup node %p -> %p\n", node, new_n); in assoc_array_gc()
1530 new_n->parent_slot = node->parent_slot; in assoc_array_gc()
1538 ptr = node->slots[slot]; in assoc_array_gc()
1709 ptr = node->back_pointer; in assoc_array_gc()
1717 slot = node->parent_slot; in assoc_array_gc()
1721 node = assoc_array_ptr_to_node(cursor); in assoc_array_gc()