lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 22 Jan 2019 02:22:41 -0800
From:   tip-bot for Arnaldo Carvalho de Melo <tipbot@...or.com>
To:     linux-tip-commits@...r.kernel.org
Cc:     tglx@...utronix.de, ast@...nel.org, linux-kernel@...r.kernel.org,
        daniel@...earbox.net, hpa@...or.com, dsahern@...il.com,
        acme@...hat.com, peterz@...radead.org, mingo@...nel.org,
        songliubraving@...com
Subject: [tip:perf/core] perf top: Synthesize BPF events for pre-existing
 loaded BPF programs

Commit-ID:  a40b95bcd30cf77c6c7a00f879dfecbded47b3bd
Gitweb:     https://git.kernel.org/tip/a40b95bcd30cf77c6c7a00f879dfecbded47b3bd
Author:     Arnaldo Carvalho de Melo <acme@...hat.com>
AuthorDate: Thu, 17 Jan 2019 08:15:20 -0800
Committer:  Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Mon, 21 Jan 2019 17:38:56 -0300

perf top: Synthesize BPF events for pre-existing loaded BPF programs

So that we can resolve symbols and map names.

Cc: Alexei Starovoitov <ast@...nel.org>
Cc: Daniel Borkmann <daniel@...earbox.net>
Cc: David Ahern <dsahern@...il.com>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Song Liu <songliubraving@...com>
Cc: kernel-team@...com
Cc: netdev@...r.kernel.org
Link: http://lkml.kernel.org/r/20190117161521.1341602-9-songliubraving@fb.com
Signed-off-by: Song Liu <songliubraving@...com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
 tools/perf/builtin-top.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/tools/perf/builtin-top.c b/tools/perf/builtin-top.c
index f64e312db787..5a486d4de56e 100644
--- a/tools/perf/builtin-top.c
+++ b/tools/perf/builtin-top.c
@@ -22,6 +22,7 @@
 #include "perf.h"
 
 #include "util/annotate.h"
+#include "util/bpf-event.h"
 #include "util/config.h"
 #include "util/color.h"
 #include "util/drv_configs.h"
@@ -1215,6 +1216,12 @@ static int __cmd_top(struct perf_top *top)
 
 	init_process_thread(top);
 
+	ret = perf_event__synthesize_bpf_events(&top->tool, perf_event__process,
+						&top->session->machines.host,
+						&top->record_opts);
+	if (ret < 0)
+		pr_warning("Couldn't synthesize bpf events.\n");
+
 	machine__synthesize_threads(&top->session->machines.host, &opts->target,
 				    top->evlist->threads, false,
 				    top->nr_threads_synthesize);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ