diff options
Diffstat (limited to 'tools/perf/util/session.h')
-rw-r--r-- | tools/perf/util/session.h | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/tools/perf/util/session.h b/tools/perf/util/session.h index 36d1a80c0b6c..752d75aebade 100644 --- a/tools/perf/util/session.h +++ b/tools/perf/util/session.h | |||
@@ -3,13 +3,13 @@ | |||
3 | 3 | ||
4 | #include "event.h" | 4 | #include "event.h" |
5 | #include "header.h" | 5 | #include "header.h" |
6 | #include "symbol.h" | ||
6 | #include "thread.h" | 7 | #include "thread.h" |
7 | #include <linux/rbtree.h> | 8 | #include <linux/rbtree.h> |
8 | #include "../../../include/linux/perf_event.h" | 9 | #include "../../../include/linux/perf_event.h" |
9 | 10 | ||
10 | struct ip_callchain; | 11 | struct ip_callchain; |
11 | struct thread; | 12 | struct thread; |
12 | struct symbol; | ||
13 | 13 | ||
14 | struct perf_session { | 14 | struct perf_session { |
15 | struct perf_header header; | 15 | struct perf_header header; |
@@ -24,10 +24,7 @@ struct perf_session { | |||
24 | unsigned long unknown_events; | 24 | unsigned long unknown_events; |
25 | struct rb_root hists; | 25 | struct rb_root hists; |
26 | u64 sample_type; | 26 | u64 sample_type; |
27 | struct { | 27 | struct ref_reloc_sym ref_reloc_sym; |
28 | const char *name; | ||
29 | u64 addr; | ||
30 | } ref_reloc_sym; | ||
31 | int fd; | 28 | int fd; |
32 | int cwdlen; | 29 | int cwdlen; |
33 | char *cwd; | 30 | char *cwd; |
@@ -69,9 +66,20 @@ int perf_header__read_build_ids(struct perf_header *self, int input, | |||
69 | int perf_session__set_kallsyms_ref_reloc_sym(struct perf_session *self, | 66 | int perf_session__set_kallsyms_ref_reloc_sym(struct perf_session *self, |
70 | const char *symbol_name, | 67 | const char *symbol_name, |
71 | u64 addr); | 68 | u64 addr); |
72 | void perf_session__reloc_vmlinux_maps(struct perf_session *self, | ||
73 | u64 unrelocated_addr); | ||
74 | 69 | ||
75 | void mem_bswap_64(void *src, int byte_size); | 70 | void mem_bswap_64(void *src, int byte_size); |
76 | 71 | ||
72 | static inline int __perf_session__create_kernel_maps(struct perf_session *self, | ||
73 | struct dso *kernel) | ||
74 | { | ||
75 | return __map_groups__create_kernel_maps(&self->kmaps, | ||
76 | self->vmlinux_maps, kernel); | ||
77 | } | ||
78 | |||
79 | static inline struct map * | ||
80 | perf_session__new_module_map(struct perf_session *self, | ||
81 | u64 start, const char *filename) | ||
82 | { | ||
83 | return map_groups__new_module(&self->kmaps, start, filename); | ||
84 | } | ||
77 | #endif /* __PERF_SESSION_H */ | 85 | #endif /* __PERF_SESSION_H */ |