Go to the source code of this file.
Data Structures | |
struct | list_head |
Defines | |
#define | list_entry(ptr, type, member) ((type *)((char *)(ptr)-(unsigned long)(&((type *)0)->member))) |
#define | list_for_each(pos, head) for (pos = (head)->next; pos != (head); pos = pos->next) |
#define | list_for_each_safe(pos, n, head) |
#define | LIST_HEAD_INIT(name) { &(name), &(name) } |
#define | LIST_HEAD(name) struct list_head name = LIST_HEAD_INIT(name) |
Functions | |
static __inline__ void | list_init (struct list_head *ptr) |
static __inline__ void | __list_add (struct list_head *new_entry, struct list_head *prev, struct list_head *next) |
static __inline__ void | list_add (struct list_head *new_entry, struct list_head *head) |
static __inline__ void | list_add_tail (struct list_head *new_entry, struct list_head *head) |
static __inline__ void | __list_del (struct list_head *prev, struct list_head *next) |
static __inline__ void | list_del (struct list_head *entry) |
static __inline__ void | list_del_init (struct list_head *entry) |
static __inline__ int | list_empty (struct list_head const *head) |
static __inline__ void | list_splice (struct list_head *list, struct list_head *head) |
Kernel-style lists
Definition in file op_list.h.
#define list_entry | ( | ptr, | |||
type, | |||||
member | ) | ((type *)((char *)(ptr)-(unsigned long)(&((type *)0)->member))) |
list_entry - get the struct for this entry
ptr | the &struct list_head pointer. | |
type | the type of the struct this is embedded in. | |
member | the name of the list_struct within the struct. |
Definition at line 152 of file op_list.h.
Referenced by _add_jitdumps_to_deletion_list(), _cleanup_jitdumps(), allocate_counter(), arch_filter_events(), clear_anon_maps(), delete_counter_arc(), delete_path_names_list(), do_lru(), oprof_start::fill_events(), filter_anon_samples_list(), find_anon_dir_match(), find_anon_mapping(), find_cookie(), find_event_any(), find_event_by_name(), find_event_um(), find_kernel_image(), find_next_event(), find_samples_data(), for_each_sfile(), for_one_sfile(), get_file(), ibs_sfile_get(), is_cookie_ignored(), is_image_ignored(), load_events(), main(), op_check_events(), op_free_events(), op_process_jit_dumpfiles(), opd_24_sfile_lru_clear(), opd_clear_module_info(), opd_clear_modules(), opd_find_image(), opd_find_module_by_eip(), opd_find_module_by_name(), opd_for_each_image(), opd_for_each_proc(), opd_get_ascii_maps(), opd_get_proc(), opd_handle_fork(), opd_kill_maps(), opd_lookup_maps(), opd_remove_kernel_mapping(), opd_sync_samples_files(), operf_find_kernel_image(), operf_free_modules_list(), operf_sfile_find(), operf_sfile_lru_clear(), sfile_find(), sfile_lru_clear(), try_find_um(), and verbose_cookie().
#define list_for_each | ( | pos, | |||
head | ) | for (pos = (head)->next; pos != (head); pos = pos->next) |
list_for_each - iterate over a list
pos | the &struct list_head to use as a loop counter. | |
head | the head for your list. |
Definition at line 160 of file op_list.h.
Referenced by allocate_counter(), oprof_start::fill_events(), find_anon_dir_match(), find_anon_mapping(), find_cookie(), find_event_any(), find_event_by_name(), find_event_um(), find_kernel_image(), find_samples_data(), get_file(), ibs_sfile_get(), is_cookie_ignored(), is_image_ignored(), load_events(), main(), op_check_events(), opd_find_image(), opd_find_module_by_eip(), opd_find_module_by_name(), opd_get_ascii_maps(), opd_handle_fork(), opd_lookup_maps(), opd_sync_samples_files(), operf_find_kernel_image(), operf_sfile_find(), sfile_find(), try_find_um(), and verbose_cookie().
#define list_for_each_safe | ( | pos, | |||
n, | |||||
head | ) |
for (pos = (head)->next, n = pos->next; pos != (head); \
pos = n, n = pos->next)
list_for_each_safe - iterate over a list safe against removal of list entry
pos | the &struct list_head to use as a loop counter. | |
n | another &struct list_head to use as temporary storage | |
head | the head for your list. |
Definition at line 169 of file op_list.h.
Referenced by _add_jitdumps_to_deletion_list(), _cleanup_jitdumps(), arch_filter_events(), clear_anon_maps(), delete_counter_arc(), delete_path_names_list(), do_lru(), filter_anon_samples_list(), for_each_sfile(), for_one_sfile(), op_free_events(), op_process_jit_dumpfiles(), opd_24_sfile_lru_clear(), opd_clear_module_info(), opd_clear_modules(), opd_for_each_image(), opd_for_each_proc(), opd_get_proc(), opd_kill_maps(), opd_remove_kernel_mapping(), operf_free_modules_list(), operf_sfile_lru_clear(), and sfile_lru_clear().
#define LIST_HEAD | ( | name | ) | struct list_head name = LIST_HEAD_INIT(name) |
Definition at line 175 of file op_list.h.
Referenced by op_process_jit_dumpfiles().
static __inline__ void __list_add | ( | struct list_head * | new_entry, | |
struct list_head * | prev, | |||
struct list_head * | next | |||
) | [static] |
Definition at line 46 of file op_list.h.
References list_head::next, and list_head::prev.
Referenced by list_add(), and list_add_tail().
Definition at line 89 of file op_list.h.
References list_head::next, and list_head::prev.
Referenced by list_del(), and list_del_init().
list_add - add a new entry
new | new entry to be added | |
head | list head to add it after |
Insert a new entry after the specified head. This is good for implementing stacks.
Definition at line 64 of file op_list.h.
References __list_add(), and list_head::next.
Referenced by _add_jitdumps_to_deletion_list(), add_image_filter(), find_anon_mapping(), find_cookie(), get_file(), get_pathname(), ibs_sfile_get(), is_cookie_ignored(), odb_open(), opd_create_module(), opd_get_proc(), opd_new_image(), opd_new_proc(), operf_create_module(), operf_sfile_find(), and sfile_find().
static __inline__ void list_add_tail | ( | struct list_head * | new_entry, | |
struct list_head * | head | |||
) | [static] |
list_add_tail - add a new entry
new | new entry to be added | |
head | list head to add it before |
Insert a new entry before the specified head. This is useful for implementing queues.
Definition at line 77 of file op_list.h.
References __list_add(), and list_head::prev.
Referenced by add_anon_mapping(), build_counter_arc(), new_event(), new_unit_mask(), opd_24_sfile_lru(), opd_add_mapping(), opd_open_24_sample_file(), operf_sfile_put(), and sfile_put().
static __inline__ void list_del | ( | struct list_head * | entry | ) | [static] |
list_del - deletes entry from list.
entry | the element to delete from the list. Note: list_empty on entry does not return true after this, the entry is in an undefined state. |
Definition at line 101 of file op_list.h.
References __list_del(), list_head::next, and list_head::prev.
Referenced by _cleanup_jitdumps(), clear_anon_maps(), delete_counter_arc(), delete_event(), delete_pathname(), delete_unit_mask(), do_lru(), filter_anon_samples_list(), find_anon_mapping(), for_one_sfile(), free_event(), free_unit_mask(), kill_sfile(), odb_close(), opd_24_sfile_lru(), opd_close_image_samples_files(), opd_delete_image(), opd_delete_proc(), opd_get_proc(), opd_kill_maps(), opd_open_24_sample_file(), opd_remove_kernel_mapping(), operf_free_modules_list(), operf_sfile_get(), and sfile_get().
static __inline__ void list_del_init | ( | struct list_head * | entry | ) | [static] |
list_del_init - deletes entry from list and reinitialize it.
entry | the element to delete from the list. |
Definition at line 110 of file op_list.h.
References __list_del(), list_init(), list_head::next, and list_head::prev.
Referenced by opd_24_sfile_lru_clear().
static __inline__ int list_empty | ( | struct list_head const * | head | ) | [static] |
list_empty - tests whether a list is empty
head | the list to test. |
Definition at line 120 of file op_list.h.
References list_head::next.
Referenced by load_events(), op_process_jit_dumpfiles(), opd_24_sfile_lru_clear(), opd_add_mapping(), opd_get_ascii_maps(), operf_sfile_lru_clear(), and sfile_lru_clear().
static __inline__ void list_init | ( | struct list_head * | ptr | ) | [static] |
list_init - init a new entry
ptr | the list to init |
Init a list head to create an empty list from it
Definition at line 34 of file op_list.h.
References list_head::next, and list_head::prev.
Referenced by anon_init(), build_counter_arc(), cookie_init(), create_sfile(), init_hash(), list_del_init(), odb_open(), opd_clear_module_info(), opd_clear_modules(), opd_create_vmlinux(), opd_create_xen(), opd_init_images(), opd_init_procs(), opd_new_image(), opd_new_proc(), opd_open_24_sample_file(), opd_parse_image_filter(), operf_create_vmlinux(), operf_sfile_dup(), operf_sfile_init(), sfile_dup(), and sfile_init().
list_splice - join two lists
list | the new list to add. | |
head | the place to add it in the first list. |
Definition at line 130 of file op_list.h.
References list_head::next, and list_head::prev.