Lines Matching refs:entry
1111 struct ftrace_func_entry *entry; in __ftrace_lookup_ip() local
1117 hlist_for_each_entry_rcu_notrace(entry, hhd, hlist) { in __ftrace_lookup_ip()
1118 if (entry->ip == ip) in __ftrace_lookup_ip()
1119 return entry; in __ftrace_lookup_ip()
1144 struct ftrace_func_entry *entry) in __add_hash_entry() argument
1149 key = ftrace_hash_key(hash, entry->ip); in __add_hash_entry()
1151 hlist_add_head(&entry->hlist, hhd); in __add_hash_entry()
1157 struct ftrace_func_entry *entry; in add_hash_entry() local
1159 entry = kmalloc(sizeof(*entry), GFP_KERNEL); in add_hash_entry()
1160 if (!entry) in add_hash_entry()
1163 entry->ip = ip; in add_hash_entry()
1164 __add_hash_entry(hash, entry); in add_hash_entry()
1171 struct ftrace_func_entry *entry) in free_hash_entry() argument
1173 hlist_del(&entry->hlist); in free_hash_entry()
1174 kfree(entry); in free_hash_entry()
1180 struct ftrace_func_entry *entry) in remove_hash_entry() argument
1182 hlist_del_rcu(&entry->hlist); in remove_hash_entry()
1190 struct ftrace_func_entry *entry; in ftrace_hash_clear() local
1199 hlist_for_each_entry_safe(entry, tn, hhd, hlist) in ftrace_hash_clear()
1200 free_hash_entry(hash, entry); in ftrace_hash_clear()
1318 struct ftrace_func_entry *entry; in alloc_and_copy_ftrace_hash() local
1337 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in alloc_and_copy_ftrace_hash()
1338 ret = add_hash_entry(new_hash, entry->ip); in alloc_and_copy_ftrace_hash()
1363 struct ftrace_func_entry *entry; in dup_hash() local
1389 hlist_for_each_entry_safe(entry, tn, hhd, hlist) { in dup_hash()
1390 remove_hash_entry(src, entry); in dup_hash()
1391 __add_hash_entry(new_hash, entry); in dup_hash()
2452 struct ftrace_func_entry *entry; in ftrace_find_rec_direct() local
2454 entry = __ftrace_lookup_ip(direct_functions, ip); in ftrace_find_rec_direct()
2455 if (!entry) in ftrace_find_rec_direct()
2458 return entry->direct; in ftrace_find_rec_direct()
2465 struct ftrace_func_entry *entry; in ftrace_add_rec_direct() local
2484 entry = kmalloc(sizeof(*entry), GFP_KERNEL); in ftrace_add_rec_direct()
2485 if (!entry) in ftrace_add_rec_direct()
2488 entry->ip = ip; in ftrace_add_rec_direct()
2489 entry->direct = addr; in ftrace_add_rec_direct()
2490 __add_hash_entry(direct_functions, entry); in ftrace_add_rec_direct()
2491 return entry; in ftrace_add_rec_direct()
4054 struct ftrace_func_entry *entry; in enter_record() local
4057 entry = ftrace_lookup_ip(hash, rec->ip); in enter_record()
4060 if (!entry) in enter_record()
4063 free_hash_entry(hash, entry); in enter_record()
4066 if (entry) in enter_record()
4493 struct ftrace_func_entry entry; member
4533 struct ftrace_func_entry *entry; in ftrace_func_mapper_find_ip() local
4536 entry = ftrace_lookup_ip(&mapper->hash, ip); in ftrace_func_mapper_find_ip()
4537 if (!entry) in ftrace_func_mapper_find_ip()
4540 map = (struct ftrace_func_map *)entry; in ftrace_func_mapper_find_ip()
4555 struct ftrace_func_entry *entry; in ftrace_func_mapper_add_ip() local
4558 entry = ftrace_lookup_ip(&mapper->hash, ip); in ftrace_func_mapper_add_ip()
4559 if (entry) in ftrace_func_mapper_add_ip()
4566 map->entry.ip = ip; in ftrace_func_mapper_add_ip()
4569 __add_hash_entry(&mapper->hash, &map->entry); in ftrace_func_mapper_add_ip()
4587 struct ftrace_func_entry *entry; in ftrace_func_mapper_remove_ip() local
4591 entry = ftrace_lookup_ip(&mapper->hash, ip); in ftrace_func_mapper_remove_ip()
4592 if (!entry) in ftrace_func_mapper_remove_ip()
4595 map = (struct ftrace_func_map *)entry; in ftrace_func_mapper_remove_ip()
4598 remove_hash_entry(&mapper->hash, entry); in ftrace_func_mapper_remove_ip()
4599 kfree(entry); in ftrace_func_mapper_remove_ip()
4615 struct ftrace_func_entry *entry; in free_ftrace_func_mapper() local
4627 hlist_for_each_entry(entry, hhd, hlist) { in free_ftrace_func_mapper()
4628 map = (struct ftrace_func_map *)entry; in free_ftrace_func_mapper()
4676 struct ftrace_func_entry *entry; in register_ftrace_function_probe() local
4744 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in register_ftrace_function_probe()
4745 if (ftrace_lookup_ip(old_hash, entry->ip)) in register_ftrace_function_probe()
4754 entry->ip, data, in register_ftrace_function_probe()
4806 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in register_ftrace_function_probe()
4807 if (ftrace_lookup_ip(old_hash, entry->ip)) in register_ftrace_function_probe()
4809 probe_ops->free(probe_ops, tr, entry->ip, probe->data); in register_ftrace_function_probe()
4821 struct ftrace_func_entry *entry; in unregister_ftrace_function_probe_func() local
4887 hlist_for_each_entry_safe(entry, tmp, &hash->buckets[i], hlist) { in unregister_ftrace_function_probe_func()
4890 kallsyms_lookup(entry->ip, NULL, NULL, in unregister_ftrace_function_probe_func()
4896 remove_hash_entry(hash, entry); in unregister_ftrace_function_probe_func()
4897 hlist_add_head(&entry->hlist, &hhd); in unregister_ftrace_function_probe_func()
4925 hlist_for_each_entry_safe(entry, tmp, &hhd, hlist) { in unregister_ftrace_function_probe_func()
4926 hlist_del(&entry->hlist); in unregister_ftrace_function_probe_func()
4928 probe_ops->free(probe_ops, tr, entry->ip, probe->data); in unregister_ftrace_function_probe_func()
4929 kfree(entry); in unregister_ftrace_function_probe_func()
5096 struct ftrace_func_entry *entry; in __ftrace_match_addr() local
5103 entry = ftrace_lookup_ip(hash, ip); in __ftrace_match_addr()
5104 if (!entry) in __ftrace_match_addr()
5106 free_hash_entry(hash, entry); in __ftrace_match_addr()
5215 struct ftrace_direct_func *entry; in ftrace_find_direct_func() local
5219 list_for_each_entry_rcu(entry, &ftrace_direct_funcs, next) { in ftrace_find_direct_func()
5220 if (entry->addr == addr) { in ftrace_find_direct_func()
5226 return entry; in ftrace_find_direct_func()
5267 struct ftrace_func_entry *entry; in register_ftrace_direct() local
5311 entry = ftrace_add_rec_direct(ip, addr, &free_hash); in register_ftrace_direct()
5312 if (!entry) in register_ftrace_direct()
5324 remove_hash_entry(direct_functions, entry); in register_ftrace_direct()
5325 kfree(entry); in register_ftrace_direct()
5353 struct ftrace_func_entry *entry; in find_direct_entry() local
5360 entry = __ftrace_lookup_ip(direct_functions, rec->ip); in find_direct_entry()
5361 if (!entry) { in find_direct_entry()
5374 return entry; in find_direct_entry()
5380 struct ftrace_func_entry *entry; in unregister_ftrace_direct() local
5390 entry = find_direct_entry(&ip, NULL); in unregister_ftrace_direct()
5391 if (!entry) in unregister_ftrace_direct()
5402 remove_hash_entry(direct_functions, entry); in unregister_ftrace_direct()
5413 kfree(entry); in unregister_ftrace_direct()
5448 int __weak ftrace_modify_direct_caller(struct ftrace_func_entry *entry, in ftrace_modify_direct_caller() argument
5486 entry->direct = new_addr; in ftrace_modify_direct_caller()
5519 struct ftrace_func_entry *entry; in modify_ftrace_direct() local
5531 entry = find_direct_entry(&ip, &rec); in modify_ftrace_direct()
5532 if (!entry) in modify_ftrace_direct()
5536 if (entry->direct != old_addr) in modify_ftrace_direct()
5560 ret = ftrace_modify_direct_caller(entry, rec, old_addr, new_addr); in modify_ftrace_direct()
5562 entry->direct = new_addr; in modify_ftrace_direct()
5597 struct ftrace_func_entry *entry, *del; in remove_direct_functions_hash() local
5602 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in remove_direct_functions_hash()
5603 del = __ftrace_lookup_ip(direct_functions, entry->ip); in remove_direct_functions_hash()
5637 struct ftrace_func_entry *entry, *new; in register_ftrace_direct_multi() local
5656 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in register_ftrace_direct_multi()
5657 if (ftrace_find_rec_direct(entry->ip)) in register_ftrace_direct_multi()
5665 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in register_ftrace_direct_multi()
5666 new = ftrace_add_rec_direct(entry->ip, addr, &free_hash); in register_ftrace_direct_multi()
5669 entry->direct = addr; in register_ftrace_direct_multi()
5733 struct ftrace_func_entry *entry, *iter; in __modify_ftrace_direct_multi() local
5761 entry = __ftrace_lookup_ip(direct_functions, iter->ip); in __modify_ftrace_direct_multi()
5762 if (!entry) in __modify_ftrace_direct_multi()
5764 entry->direct = addr; in __modify_ftrace_direct_multi()
6192 struct ftrace_func_entry *entry; member
6204 struct ftrace_func_entry *entry = fgd->entry; in __g_next() local
6211 if (entry) { in __g_next()
6212 hlist_for_each_entry_continue(entry, hlist) { in __g_next()
6213 fgd->entry = entry; in __g_next()
6214 return entry; in __g_next()
6222 hlist_for_each_entry(entry, head, hlist) { in __g_next()
6223 fgd->entry = entry; in __g_next()
6225 return entry; in __g_next()
6256 fgd->entry = NULL; in g_start()
6267 struct ftrace_func_entry *entry = v; in g_show() local
6269 if (!entry) in g_show()
6272 if (entry == FTRACE_GRAPH_EMPTY) { in g_show()
6282 seq_printf(m, "%ps\n", (void *)entry->ip); in g_show()
6483 struct ftrace_func_entry *entry; in ftrace_graph_set_hash() local
6506 entry = ftrace_lookup_ip(hash, rec->ip); in ftrace_graph_set_hash()
6511 if (entry) in ftrace_graph_set_hash()
6516 if (entry) { in ftrace_graph_set_hash()
6517 free_hash_entry(hash, entry); in ftrace_graph_set_hash()
6895 struct ftrace_func_entry *entry; in clear_mod_from_hash() local
6904 entry = __ftrace_lookup_ip(hash, rec->ip); in clear_mod_from_hash()
6910 if (entry) in clear_mod_from_hash()
6911 entry->ip = 0; in clear_mod_from_hash()
7286 struct ftrace_func_entry *entry; in clear_func_from_hash() local
7288 entry = ftrace_lookup_ip(hash, func->ip); in clear_func_from_hash()
7294 if (entry) in clear_func_from_hash()
7295 entry->ip = 0; in clear_func_from_hash()
8119 struct ftrace_func_entry *entry; in prepare_direct_functions_for_ipmodify() local
8132 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in prepare_direct_functions_for_ipmodify()
8133 unsigned long ip = entry->ip; in prepare_direct_functions_for_ipmodify()
8168 struct ftrace_func_entry *entry; in cleanup_direct_functions_after_ipmodify() local
8181 hlist_for_each_entry(entry, &hash->buckets[i], hlist) { in cleanup_direct_functions_after_ipmodify()
8182 unsigned long ip = entry->ip; in cleanup_direct_functions_after_ipmodify()