aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/perf_counter/util/symbol.h
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/perf_counter/util/symbol.h')
-rw-r--r--Documentation/perf_counter/util/symbol.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/Documentation/perf_counter/util/symbol.h b/Documentation/perf_counter/util/symbol.h
index 6dffe76a28f0..9e120af9c71f 100644
--- a/Documentation/perf_counter/util/symbol.h
+++ b/Documentation/perf_counter/util/symbol.h
@@ -15,12 +15,18 @@ struct symbol {
15struct dso { 15struct dso {
16 struct list_head node; 16 struct list_head node;
17 struct rb_root syms; 17 struct rb_root syms;
18 unsigned int sym_priv_size;
18 char name[0]; 19 char name[0];
19}; 20};
20 21
21struct dso *dso__new(const char *name); 22struct dso *dso__new(const char *name, unsigned int sym_priv_size);
22void dso__delete(struct dso *self); 23void dso__delete(struct dso *self);
23 24
25static inline void *dso__sym_priv(struct dso *self, struct symbol *sym)
26{
27 return ((void *)sym) - self->sym_priv_size;
28}
29
24struct symbol *dso__find_symbol(struct dso *self, uint64_t ip); 30struct symbol *dso__find_symbol(struct dso *self, uint64_t ip);
25 31
26int dso__load_kallsyms(struct dso *self); 32int dso__load_kallsyms(struct dso *self);