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] [day] [month] [year] [list]
Message-ID: <Zg1kCT3V3n9l0fJc@x1>
Date: Wed, 3 Apr 2024 11:13:29 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Namhyung Kim <namhyung@...nel.org>
Cc: Ian Rogers <irogers@...gle.com>, Kan Liang <kan.liang@...ux.intel.com>,
	Jiri Olsa <jolsa@...nel.org>,
	Adrian Hunter <adrian.hunter@...el.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...nel.org>, LKML <linux-kernel@...r.kernel.org>,
	linux-perf-users@...r.kernel.org
Subject: Re: [PATCH v2 3/5] perf annotate: Split out util/disasm.c

On Tue, Apr 02, 2024 at 04:03:33PM -0700, Namhyung Kim wrote:
> On Tue, Apr 2, 2024 at 3:11 PM Arnaldo Carvalho de Melo <acme@...nel.org> wrote:
> >
> > On Tue, Apr 02, 2024 at 07:08:04PM -0300, Arnaldo Carvalho de Melo wrote:
> > > On Fri, Mar 29, 2024 at 02:58:10PM -0700, Namhyung Kim wrote:
> > > > The util/annotate.c code has both disassembly and sample annotation
> > > > related codes.  Factor out the disasm part so that it can be handled
> > > > more easily.
> > > >
> > > > No functional changes intended.
> > > >
> > >
> > > Unsure if here, will check and fix later, detected with:
> > >
> > >   make -C tools/perf build-test'
> >
> > did it, added the missing env.h header to disasm.c

> Thanks a lot!

Three more, also fixed:

util/disasm.c: In function ‘symbol__disassemble_bpf’:
util/disasm.c:1203:9: error: implicit declaration of function ‘perf_exe’ [-Werror=implicit-function-declaration]
 1203 |         perf_exe(tpath, sizeof(tpath));
      |         ^~~~~~~~



diff --git a/tools/perf/util/disasm.c b/tools/perf/util/disasm.c
index 3438c31437f46e71..c2664215554d0bb3 100644
--- a/tools/perf/util/disasm.c
+++ b/tools/perf/util/disasm.c
@@ -21,6 +21,7 @@
 #include "maps.h"
 #include "srcline.h"
 #include "symbol.h"
+#include "util.h"
 
 static regex_t	 file_lineno;
 
util/disasm.c:1229:32: error: invalid use of undefined type ‘struct bpf_prog_info_node’
 1229 |         info_linear = info_node->info_linear;
      |                                ^~
util/disasm.c: In function ‘symbol__disassemble_bpf’:
util/disasm.c:1230:32: error: invalid use of undefined type ‘struct bpf_prog_info_node’
 1230 |         info_linear = info_node->info_linear;
      |                                ^~


diff --git a/tools/perf/util/disasm.c b/tools/perf/util/disasm.c
index c2664215554d0bb3..5b5407525b31f47f 100644
--- a/tools/perf/util/disasm.c
+++ b/tools/perf/util/disasm.c
@@ -1170,6 +1170,8 @@ static int dso__disassemble_filename(struct dso *dso, char *filename, size_t fil
 #include <linux/btf.h>
 #include <tools/dis-asm-compat.h>
 
+#include "bpf-event.h"
+
 static int symbol__disassemble_bpf(struct symbol *sym,
 				   struct annotate_args *args)
 {

util/disasm.c: In function ‘symbol__disassemble_bpf’:
util/disasm.c:1235:54: error: invalid use of undefined type ‘struct perf_bpil’
 1235 |         info.buffer = (void *)(uintptr_t)(info_linear->info.jited_prog_insns);
      | 

diff --git a/tools/perf/util/disasm.c b/tools/perf/util/disasm.c
index a88d33fd38a58e4a..a1219eb930aaeb5a 100644
--- a/tools/perf/util/disasm.c
+++ b/tools/perf/util/disasm.c
@@ -1173,6 +1173,7 @@ static int dso__disassemble_filename(struct dso *dso, char *filename, size_t fil
 #include <tools/dis-asm-compat.h>
 
 #include "bpf-event.h"
+#include "bpf-utils.h"
 
 static int symbol__disassemble_bpf(struct symbol *sym,
 				   struct annotate_args *args)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ