summaryrefslogtreecommitdiff
path: root/kern/rdxtree.c
diff options
context:
space:
mode:
authorRichard Braun <rbraun@sceen.net>2018-02-24 07:25:55 +0100
committerRichard Braun <rbraun@sceen.net>2018-02-24 07:25:55 +0100
commitc31ddfaf11320dea4828c753f48a29041643f552 (patch)
tree88b5c776170c406f90e686c347c7b9fef09d9c38 /kern/rdxtree.c
parent6a69c45189d3c576cc18dfac6e426cd606831657 (diff)
kern/{cbuf,fmt,hash,hlist,list,plist,rdxtree,shell,slist}: update from upstream
Note that this commit changes the order of some list operations without triggering warnings.
Diffstat (limited to 'kern/rdxtree.c')
-rw-r--r--kern/rdxtree.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/kern/rdxtree.c b/kern/rdxtree.c
index ac73a107..41765f54 100644
--- a/kern/rdxtree.c
+++ b/kern/rdxtree.c
@@ -119,7 +119,7 @@ rdxtree_entry_addr(void *entry)
return (void *)((uintptr_t)entry & RDXTREE_ENTRY_ADDR_MASK);
}
-static inline int
+static inline bool
rdxtree_entry_is_node(const void *entry)
{
return ((uintptr_t)entry & 1) != 0;
@@ -208,13 +208,13 @@ rdxtree_node_unlink(struct rdxtree_node *node)
node->parent = NULL;
}
-static inline int
+static inline bool
rdxtree_node_full(struct rdxtree_node *node)
{
return (node->nr_entries == ARRAY_SIZE(node->entries));
}
-static inline int
+static inline bool
rdxtree_node_empty(struct rdxtree_node *node)
{
return (node->nr_entries == 0);
@@ -282,13 +282,13 @@ rdxtree_node_bm_clear(struct rdxtree_node *node, unsigned short index)
node->alloc_bm &= ~((rdxtree_bm_t)1 << index);
}
-static inline int
+static inline bool
rdxtree_node_bm_is_set(struct rdxtree_node *node, unsigned short index)
{
return (node->alloc_bm & ((rdxtree_bm_t)1 << index));
}
-static inline int
+static inline bool
rdxtree_node_bm_empty(struct rdxtree_node *node)
{
return (node->alloc_bm == RDXTREE_BM_EMPTY);
@@ -684,7 +684,7 @@ rdxtree_remove(struct rdxtree *tree, rdxtree_key_t key)
void *
rdxtree_lookup_common(const struct rdxtree *tree, rdxtree_key_t key,
- int get_slot)
+ bool get_slot)
{
struct rdxtree_node *node, *prev;
unsigned short height, shift, index;