|
libosmocore 1.10.0.47-38eb4
Osmocom core library
|
Go to the source code of this file.
Macros | |
| #define | DEFINE_HASHTABLE(name, bits) |
| #define | DECLARE_HASHTABLE(name, bits) |
| #define | HASH_SIZE(name) |
| #define | HASH_BITS(name) |
| #define | hash_min(val, bits) |
| #define | hash_init(hashtable) |
| hash_init - initialize a hash table @hashtable: hashtable to be initialized | |
| #define | hash_add(hashtable, node, key) |
| hash_add - add an object to a hashtable @hashtable: hashtable to add to @node: the &struct hlist_node of the object to be added @key: the key of the object to be added | |
| #define | hash_empty(hashtable) |
| hash_empty - check whether a hashtable is empty @hashtable: hashtable to check | |
: hashtable to iterate | |
hash_for_each_possible_safe - iterate over all possible objects hashing to the same bucket safe against removals @obj: the type * to use as a loop cursor for each entry @tmp: a &struct hlist_node used for temporary storage @member: the name of the hlist_node within the struct @key: the key of the objects to iterate over | |
| #define | hash_for_each(name, bkt, obj, member) |
| #define | hash_for_each_safe(name, bkt, tmp, obj, member) |
| #define | hash_for_each_possible(name, obj, member, key) |
| #define | hash_for_each_possible_safe(name, obj, tmp, member, key) |
Functions | |
| static void | __hash_init (struct hlist_head *ht, unsigned int sz) |
| static bool | hash_hashed (struct hlist_node *node) |
| hash_hashed - check whether an object is in any hashtable @node: the &struct hlist_node of the object to be checked | |
| static bool | __hash_empty (struct hlist_head *ht, unsigned int sz) |
| static void | hash_del (struct hlist_node *node) |
| hash_del - remove an object from a hashtable @node: &struct hlist_node of the object to remove | |
| #define DECLARE_HASHTABLE | ( | name, | |
| bits ) |
| #define DEFINE_HASHTABLE | ( | name, | |
| bits ) |
| #define hash_add | ( | hashtable, | |
| node, | |||
| key ) |
hash_add - add an object to a hashtable @hashtable: hashtable to add to @node: the &struct hlist_node of the object to be added @key: the key of the object to be added
| #define HASH_BITS | ( | name | ) |
| #define hash_empty | ( | hashtable | ) |
hash_empty - check whether a hashtable is empty @hashtable: hashtable to check
This has to be a macro since HASH_BITS() will not work on pointers since it calculates the size during preprocessing.
| #define hash_for_each | ( | name, | |
| bkt, | |||
| obj, | |||
| member ) |
| #define hash_for_each_possible | ( | name, | |
| obj, | |||
| member, | |||
| key ) |
| #define hash_for_each_possible_safe | ( | name, | |
| obj, | |||
| tmp, | |||
| member, | |||
| key ) |
| #define hash_for_each_safe | ( | name, | |
| bkt, | |||
| tmp, | |||
| obj, | |||
| member ) |
| #define hash_init | ( | hashtable | ) |
hash_init - initialize a hash table @hashtable: hashtable to be initialized
Calculates the size of the hashtable from the given parameter, otherwise same as hash_init_size.
This has to be a macro since HASH_BITS() will not work on pointers since it calculates the size during preprocessing.
| #define hash_min | ( | val, | |
| bits ) |
| #define HASH_SIZE | ( | name | ) |
|
inlinestatic |
References hlist_empty().
|
inlinestatic |
References INIT_HLIST_HEAD.
|
inlinestatic |
hash_del - remove an object from a hashtable @node: &struct hlist_node of the object to remove
References hlist_del_init(), and node.
|
inlinestatic |
hash_hashed - check whether an object is in any hashtable @node: the &struct hlist_node of the object to be checked
References hlist_unhashed(), and node.