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]
Date:	Mon, 3 Aug 2015 22:12:00 +0200
From:	Jiri Olsa <jolsa@...hat.com>
To:	Arnaldo Carvalho de Melo <acme@...nel.org>
Cc:	Ingo Molnar <mingo@...nel.org>, linux-kernel@...r.kernel.org,
	Adrian Hunter <adrian.hunter@...el.com>,
	Borislav Petkov <bp@...e.de>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Namhyung Kim <namhyung@...nel.org>,
	Stephane Eranian <eranian@...gle.com>,
	Steven Rostedt <rostedt@...dmis.org>
Subject: Re: [PATCH 11/18] perf script: Switch from perf.data's kallsyms to
 perf's symbol resolver

On Mon, Aug 03, 2015 at 04:27:59PM -0300, Arnaldo Carvalho de Melo wrote:
> Em Mon, Aug 03, 2015 at 04:00:09PM -0300, Arnaldo Carvalho de Melo escreveu:
> > Em Mon, Aug 03, 2015 at 07:41:13PM +0200, Jiri Olsa escreveu:
> > >     Missing separate debuginfos, use: dnf debuginfo-install glibc-2.21-7.fc22.x86_64
> > >     [Thread debugging using libthread_db enabled]
> > >     Using host libthread_db library "/lib64/libthread_db.so.1".
> > >     Detaching after fork from child process 11230.
> > >      
> > >     Program received signal SIGSEGV, Segmentation fault.
> > >     0x00000000004eeace in pevent_set_function_resolver (pevent=0x0, func=0x4a3197 <machine__resolve_kernel_addr>, priv=0x18e1f48) at event-parse.c:464
> > >     464             free(pevent->func_resolver);
> > >     Missing separate debuginfos, use: dnf debuginfo-install audit-libs-2.4.3-1.fc22.x86_64 bzip2-libs-1.0.6-14.fc22.x86_64 elfutils-libelf-0.163-1.fc22.x86_64 elfutils-libs-0.163-1.fc22.x86_64 libunwind-1.1-10.fc22.x86_64 nss-softokn-freebl-3.19.2-1.0.fc22.x86_64 numactl-libs-2.0.10-2.fc22.x86_64 perl-libs-5.20.2-326.fc22.x86_64 python-libs-2.7.10-4.fc22.x86_64 slang-2.3.0-2.fc22.x86_64 xz-libs-5.2.0-2.fc22.x86_64 zlib-1.2.8-7.fc22.x86_64
> > >     (gdb)
> > 
> > > I think 'session->tevent.pevent' gets initialized only for tracepoint, right?
> > 
> > Reproduced, checking.
> 
> Yeah, I think we only need to set libtraceevent's function resolver if
> there are tracepoints, i.e. if libtraceevent is being used. Following
> patch should be enough, right?
> 
> - Arnaldo
> 
> diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c
> index bd31380122f9..7912feb9a024 100644
> --- a/tools/perf/builtin-script.c
> +++ b/tools/perf/builtin-script.c
> @@ -1861,7 +1861,8 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused)
>  	else
>  		symbol_conf.use_callchain = false;
>  
> -	if (pevent_set_function_resolver(session->tevent.pevent,
> +	if (session->tevent.pevent &&
> +	    pevent_set_function_resolver(session->tevent.pevent,
>  					 machine__resolve_kernel_addr,
>  					 &session->machines.host) < 0) {
>  		pr_err("%s: failed to set libtraceevent function resolver\n", __func__);

yep, works nicely

thanks,
jirka
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ