Function report |
Source Code:kernel\bpf\hashtab.c |
Create Date:2022-07-28 13:09:43 |
Last Modify:2022-05-23 09:15:29 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Called from syscall
Proto:static int htab_map_get_next_key(struct bpf_map *map, void *key, void *next_key)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
struct bpf_map * | map | |
void * | key | |
void * | next_key |
603 | i = 0 |
605 | WARN_ON_ONCE(!_read_lock_held() - might we be in RCU read-side critical section?* If CONFIG_DEBUG_LOCK_ALLOC is selected, returns nonzero iff in an RCU* read-side critical section) |
609 | If Not key Then Go to find_first_elem |
612 | hash = htab_map_hash(key, key_size, hashrnd) |
614 | head = select_bucket(htab, hash) |
617 | l = an be called without bucket lock. it will repeat the loop in* the unlikely event when elements moved from one bucket into another* while link list is being walked |
619 | If Not l Then Go to find_first_elem |
623 | next_l = hlist_nulls_entry_safe(Dependency order vs. p above. (hlist_nulls_next_rcu( & hash_node)), structhtab_elem, hash_node) |
626 | If next_l Then |
628 | No 3D Now!(next_key, key, key_size) |
629 | Return 0 |
633 | i = hash & number of hash buckets - 1 |
634 | i++ |
636 | find_first_elem : |
638 | When i < number of hash buckets cycle |
639 | head = select_bucket(htab, i) |
642 | next_l = hlist_nulls_entry_safe(Dependency order vs. p above. (hlist_nulls_first_rcu(head)), structhtab_elem, hash_node) |
644 | If next_l Then |
646 | No 3D Now!(next_key, key, key_size) |
647 | Return 0 |
652 | Return -ENOENT |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |