Lines Matching refs:rb_node

23 struct rb_node {  struct
25 struct rb_node *rb_right; argument
26 struct rb_node *rb_left; argument
31 struct rb_node *rb_node; member
34 #define rb_parent(r) ((struct rb_node *)((r)->__rb_parent_color & ~3))
39 #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
48 extern void rb_insert_color(struct rb_node *, struct rb_root *);
49 extern void rb_erase(struct rb_node *, struct rb_root *);
53 extern struct rb_node *rb_next(const struct rb_node *);
54 extern struct rb_node *rb_prev(const struct rb_node *);
55 extern struct rb_node *rb_first(const struct rb_root *);
56 extern struct rb_node *rb_last(const struct rb_root *);
59 extern struct rb_node *rb_first_postorder(const struct rb_root *);
60 extern struct rb_node *rb_next_postorder(const struct rb_node *);
63 extern void rb_replace_node(struct rb_node *victim, struct rb_node *new,
66 static inline void rb_link_node(struct rb_node *node, struct rb_node *parent, in rb_link_node()
67 struct rb_node **rb_link) in rb_link_node()
103 static inline void rb_erase_init(struct rb_node *n, struct rb_root *root) in rb_erase_init()
121 struct rb_node *rb_leftmost;
129 static inline void rb_insert_color_cached(struct rb_node *node, in rb_insert_color_cached()
138 static inline void rb_erase_cached(struct rb_node *node, in rb_erase_cached()
146 static inline void rb_replace_node_cached(struct rb_node *victim, in rb_replace_node_cached()
147 struct rb_node *new, in rb_replace_node_cached()
178 rb_add_cached(struct rb_node *node, struct rb_root_cached *tree, in rb_add_cached()
179 bool (*less)(struct rb_node *, const struct rb_node *)) in rb_add_cached() argument
181 struct rb_node **link = &tree->rb_root.rb_node; in rb_add_cached()
182 struct rb_node *parent = NULL; in rb_add_cached()
206 rb_add(struct rb_node *node, struct rb_root *tree, in rb_add()
207 bool (*less)(struct rb_node *, const struct rb_node *)) in rb_add() argument
209 struct rb_node **link = &tree->rb_node; in rb_add()
210 struct rb_node *parent = NULL; in rb_add()
233 static __always_inline struct rb_node *
234 rb_find_add(struct rb_node *node, struct rb_root *tree, in rb_find_add()
235 int (*cmp)(struct rb_node *, const struct rb_node *)) in rb_find_add() argument
237 struct rb_node **link = &tree->rb_node; in rb_find_add()
238 struct rb_node *parent = NULL; in rb_find_add()
266 static __always_inline struct rb_node *
268 int (*cmp)(const void *key, const struct rb_node *)) in rb_find() argument
270 struct rb_node *node = tree->rb_node; in rb_find()
294 static __always_inline struct rb_node *
296 int (*cmp)(const void *key, const struct rb_node *)) in rb_find_first() argument
298 struct rb_node *node = tree->rb_node; in rb_find_first()
299 struct rb_node *match = NULL; in rb_find_first()
324 static __always_inline struct rb_node *
325 rb_next_match(const void *key, struct rb_node *node, in rb_next_match()
326 int (*cmp)(const void *key, const struct rb_node *)) in rb_next_match() argument