diff --git a/tools/perf/util/map.c b/tools/perf/util/map.c index 59cab31e79d41054a19a1e222362a37f32aef461..1803d3887afed315373c01f3ff57298d73c52929 100644 --- a/tools/perf/util/map.c +++ b/tools/perf/util/map.c @@ -513,7 +513,7 @@ u64 map__objdump_2mem(struct map *map, u64 ip) return ip + map->reloc; } -bool map__contains_symbol(struct map *map, struct symbol *sym) +bool map__contains_symbol(const struct map *map, const struct symbol *sym) { u64 ip = map->unmap_ip(map, sym->start); diff --git a/tools/perf/util/map.h b/tools/perf/util/map.h index 212a9468d5e104283209ab7c3b924c8fe6cbd458..3dcfe06db6b3300c879d4dc24c13219449b2073b 100644 --- a/tools/perf/util/map.h +++ b/tools/perf/util/map.h @@ -152,7 +152,7 @@ static inline bool __map__is_kmodule(const struct map *map) bool map__has_symbols(const struct map *map); -bool map__contains_symbol(struct map *map, struct symbol *sym); +bool map__contains_symbol(const struct map *map, const struct symbol *sym); #define ENTRY_TRAMPOLINE_NAME "__entry_SYSCALL_64_trampoline"