Lines Matching refs:root
133 struct ubi_wl_entry *e, struct rb_root *root);
145 static void wl_tree_add(struct ubi_wl_entry *e, struct rb_root *root) in wl_tree_add() argument
149 p = &root->rb_node; in wl_tree_add()
170 rb_insert_color(&e->u.rb, root); in wl_tree_add()
242 static int in_wl_tree(struct ubi_wl_entry *e, struct rb_root *root) in in_wl_tree() argument
246 p = root->rb_node; in in_wl_tree()
304 struct rb_root *root, int diff) in find_wl_entry() argument
310 e = rb_entry(rb_first(root), struct ubi_wl_entry, u.rb); in find_wl_entry()
313 p = root->rb_node; in find_wl_entry()
347 struct rb_root *root) in find_mean_wl_entry() argument
351 first = rb_entry(rb_first(root), struct ubi_wl_entry, u.rb); in find_mean_wl_entry()
352 last = rb_entry(rb_last(root), struct ubi_wl_entry, u.rb); in find_mean_wl_entry()
355 e = rb_entry(root->rb_node, struct ubi_wl_entry, u.rb); in find_mean_wl_entry()
360 e = may_reserve_for_fm(ubi, e, root); in find_mean_wl_entry()
362 e = find_wl_entry(ubi, root, WL_FREE_MAX_DIFF/2); in find_mean_wl_entry()
1412 static void tree_destroy(struct ubi_device *ubi, struct rb_root *root) argument
1417 rb = root->rb_node;
1593 ubi_rb_for_each_entry(rb2, aeb, &av->root, u.rb) {
1750 struct ubi_wl_entry *e, struct rb_root *root) argument
1755 if (in_wl_tree(e, root))
1759 e->pnum, e->ec, root);