Lines Matching refs:enode

452 enum maple_type mas_parent_type(struct ma_state *mas, struct maple_enode *enode)  in mas_parent_type()  argument
456 p_type = (unsigned long)mte_to_node(enode)->parent; in mas_parent_type()
482 void mas_set_parent(struct ma_state *mas, struct maple_enode *enode, in mas_set_parent() argument
508 mte_to_node(enode)->parent = ma_parent_ptr(val); in mas_set_parent()
517 static inline unsigned int mte_parent_slot(const struct maple_enode *enode) in mte_parent_slot() argument
519 unsigned long val = (unsigned long)mte_to_node(enode)->parent; in mte_parent_slot()
537 static inline struct maple_node *mte_parent(const struct maple_enode *enode) in mte_parent() argument
540 (mte_to_node(enode)->parent) & ~MAPLE_NODE_MASK); in mte_parent()
565 static inline bool mte_dead_node(const struct maple_enode *enode) in mte_dead_node() argument
569 node = mte_to_node(enode); in mte_dead_node()
572 parent = mte_parent(enode); in mte_dead_node()
1002 static void mt_destroy_walk(struct maple_enode *enode, struct maple_tree *mt,
2221 static inline struct maple_enode *mte_node_or_none(struct maple_enode *enode) in mte_node_or_none() argument
2223 if (enode) in mte_node_or_none()
2224 return enode; in mte_node_or_none()
2548 struct maple_enode *enode, bool in_rcu) in mas_topiary_node() argument
2552 if (enode == MAS_NONE) in mas_topiary_node()
2555 tmp = mte_to_node(enode); in mas_topiary_node()
2556 mte_set_node_dead(enode); in mas_topiary_node()
4524 struct maple_enode *enode; in mas_next_node() local
4555 enode = mas_slot(mas, slots, mas->offset); in mas_next_node()
4564 mas->node = enode; in mas_next_node()
4568 enode = mas_slot(mas, slots, 0); in mas_next_node()
4580 mas->node = enode; in mas_next_node()
5140 unsigned char mte_dead_leaves(struct maple_enode *enode, struct maple_tree *mt, in mte_dead_leaves() argument
5148 for (offset = 0; offset < mt_slot_count(enode); offset++) { in mte_dead_leaves()
5171 static void __rcu **mte_dead_walk(struct maple_enode **enode, unsigned char offset) in mte_dead_walk() argument
5176 next = mte_to_node(*enode); in mte_dead_walk()
5178 *enode = ma_enode_ptr(next); in mte_dead_walk()
5179 node = mte_to_node(*enode); in mte_dead_walk()
5199 struct maple_enode *enode; in mt_free_walk() local
5209 enode = mt_mk_node(node, node->type); in mt_free_walk()
5210 slots = mte_dead_walk(&enode, 0); in mt_free_walk()
5211 node = mte_to_node(enode); in mt_free_walk()
5215 enode = node->piv_parent; in mt_free_walk()
5216 if (mte_to_node(enode) == node) in mt_free_walk()
5219 type = mte_node_type(enode); in mt_free_walk()
5220 slots = ma_slots(mte_to_node(enode), type); in mt_free_walk()
5224 slots = mte_dead_walk(&enode, offset); in mt_free_walk()
5225 node = mte_to_node(enode); in mt_free_walk()
5235 static inline void __rcu **mte_destroy_descend(struct maple_enode **enode, in mte_destroy_descend() argument
5239 struct maple_enode *next = *enode; in mte_destroy_descend()
5245 *enode = next; in mte_destroy_descend()
5246 node = mte_to_node(*enode); in mte_destroy_descend()
5247 type = mte_node_type(*enode); in mte_destroy_descend()
5253 mte_set_node_dead(*enode); in mte_destroy_descend()
5259 prev = *enode; in mte_destroy_descend()
5265 static void mt_destroy_walk(struct maple_enode *enode, struct maple_tree *mt, in mt_destroy_walk() argument
5269 struct maple_node *node = mte_to_node(enode); in mt_destroy_walk()
5272 if (mte_is_leaf(enode)) { in mt_destroy_walk()
5273 node->type = mte_node_type(enode); in mt_destroy_walk()
5277 start = enode; in mt_destroy_walk()
5278 slots = mte_destroy_descend(&enode, mt, start, 0); in mt_destroy_walk()
5279 node = mte_to_node(enode); // Updated in the above call. in mt_destroy_walk()
5285 node->slot_len = mte_dead_leaves(enode, mt, slots); in mt_destroy_walk()
5289 enode = node->piv_parent; in mt_destroy_walk()
5290 if (mte_to_node(enode) == node) in mt_destroy_walk()
5293 type = mte_node_type(enode); in mt_destroy_walk()
5294 slots = ma_slots(mte_to_node(enode), type); in mt_destroy_walk()
5300 parent = enode; in mt_destroy_walk()
5301 enode = tmp; in mt_destroy_walk()
5302 slots = mte_destroy_descend(&enode, mt, parent, offset); in mt_destroy_walk()
5305 node = mte_to_node(enode); in mt_destroy_walk()
5306 } while (start != enode); in mt_destroy_walk()
5308 node = mte_to_node(enode); in mt_destroy_walk()
5309 node->slot_len = mte_dead_leaves(enode, mt, slots); in mt_destroy_walk()
5327 static inline void mte_destroy_walk(struct maple_enode *enode, in mte_destroy_walk() argument
5330 struct maple_node *node = mte_to_node(enode); in mte_destroy_walk()
5333 mt_destroy_walk(enode, mt, false); in mte_destroy_walk()
5336 mt_destroy_walk(enode, mt, true); in mte_destroy_walk()
5610 struct maple_enode *enode = mas->node; in mas_expected_entries() local
5650 mas->node = enode; in mas_expected_entries()