From 75be6cf48738aec68aac49b428423569492cfba3 Mon Sep 17 00:00:00 2001 From: Arnaldo Carvalho de Melo Date: Tue, 15 Dec 2009 20:04:39 -0200 Subject: perf symbols: Make symbol_conf global MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This simplifies a lot of functions, less stuff to be done by tool writers. Signed-off-by: Arnaldo Carvalho de Melo Cc: Frédéric Weisbecker Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Paul Mackerras LKML-Reference: <1260914682-29652-1-git-send-email-acme@infradead.org> Signed-off-by: Ingo Molnar --- tools/perf/builtin-top.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'tools/perf/builtin-top.c') diff --git a/tools/perf/builtin-top.c b/tools/perf/builtin-top.c index 296e809c253..cd89b6d036b 100644 --- a/tools/perf/builtin-top.c +++ b/tools/perf/builtin-top.c @@ -80,7 +80,6 @@ static int dump_symtab = 0; static bool hide_kernel_symbols = false; static bool hide_user_symbols = false; static struct winsize winsize; -static struct symbol_conf symbol_conf; /* * Source @@ -1162,8 +1161,7 @@ static int __cmd_top(void) * FIXME: perf_session__new should allow passing a O_MMAP, so that all this * mmap reading, etc is encapsulated in it. Use O_WRONLY for now. */ - struct perf_session *session = perf_session__new(NULL, O_WRONLY, false, - &symbol_conf); + struct perf_session *session = perf_session__new(NULL, O_WRONLY, false); if (session == NULL) return -ENOMEM; @@ -1284,7 +1282,7 @@ int cmd_top(int argc, const char **argv, const char *prefix __used) (nr_counters + 1) * sizeof(unsigned long)); if (symbol_conf.vmlinux_name == NULL) symbol_conf.try_vmlinux_path = true; - if (symbol__init(&symbol_conf) < 0) + if (symbol__init() < 0) return -1; if (delay_secs < 1) -- cgit v1.2.3