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]
Message-ID: <20160111112534.GA4921@gmail.com>
Date:	Mon, 11 Jan 2016 12:25:34 +0100
From:	Ingo Molnar <mingo@...nel.org>
To:	He Kuang <hekuang@...wei.com>
Cc:	peterz@...radead.org, mingo@...hat.com, acme@...nel.org,
	jolsa@...hat.com, rabin.vincent@...s.com, namhyung@...nel.org,
	wangnan0@...wei.com, mark.rutland@....com,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] perf symbols: Fix wrong symbol offset according to p_addr


* He Kuang <hekuang@...wei.com> wrote:

> Perf missed the 'VirtAddr' value in elf program_headers when adjusting
> symbol address for dynamic libraries. This patch considers the p_addr
> value and gets the right symbol offset.

s/gets/calculates

> 
> Before this patch, some symbols can not be right parsed on android phone:

s/Before this patch, some symbols are not parsed correctly on android phones:

> 
>   init   369 [002]   339.970607: raw_syscalls:sys_enter: NR 22 (b, 7fd9e360a0, 10, ffffffff, 0, 8)
>                      ...
>                    230ac [unknown] (/system/lib64/libsurfaceflinger.so)
>                     11a0 main (/system/bin/surfaceflinger)
>                    1c3fc __libc_init (/system/lib64/libc.so)
>                      fd0 _start (/system/bin/surfaceflinger)
>                     29ec __dl__start (/system/bin/linker64)
> 
> After this patch:
> 
>   init   369 [002]   339.970607: raw_syscalls:sys_enter: NR 22 (b, 7fd9e360a0, 10, ffffffff, 0, 8)
>                      ...
>                    3a0ac _ZN7android14SurfaceFlinger3runEv (/system/lib64/libsurfaceflinger.so)
>                     11a0 main (/system/bin/surfaceflinger)
>                    1c3fc __libc_init (/system/lib64/libc.so)
>                      fd0 _start (/system/bin/surfaceflinger)
>                     29ec __dl__start (/system/bin/linker64)

> --- a/tools/perf/util/dso.h
> +++ b/tools/perf/util/dso.h
> @@ -166,6 +166,7 @@ struct dso {
>  	const char	 *long_name;
>  	u16		 long_name_len;
>  	u16		 short_name_len;
> +	u64		vaddr;
>  	void		*dwfl;			/* DWARF debug info */

btw., looks like there's some extra spaces in front of those other field 
definitions.

Also, might make sense to describe what 'vaddr' stands for precisely, the naming 
is pretty ambiguous.

Thanks,

	Ingo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ