linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@infradead.org>
To: Ingo Molnar <mingo@elte.hu>
Cc: linux-kernel@vger.kernel.org, Franck Bui-Huu <fbuihuu@gmail.com>,
	2nddept-manager@sdl.hitachi.co.jp,
	Francis Moreau <francis.moro@gmail.com>,
	Franck Bui-Huu <vagabon.xyz@gmail.com>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH 2/2] perf symbols: Stop using vmlinux files with no symbols
Date: Sun, 12 Dec 2010 13:16:54 -0200	[thread overview]
Message-ID: <1292167014-20936-3-git-send-email-acme@infradead.org> (raw)
In-Reply-To: <1292167014-20936-1-git-send-email-acme@infradead.org>

From: Franck Bui-Huu <fbuihuu@gmail.com>

Fail if the kernel image contains no symbol, allowing using other images
in the vmlinux search path that may have a usable symtab.

Cc: 2nddept-manager@sdl.hitachi.co.jp
Cc: Francis Moreau <francis.moro@gmail.com>
Cc: Franck Bui-Huu <vagabon.xyz@gmail.com>
Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
LPU-Reference: <m3d3p9ydx9.fsf_-_@gmail.com>
Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/util/probe-event.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c
index b71acd6..61191c6 100644
--- a/tools/perf/util/probe-event.c
+++ b/tools/perf/util/probe-event.c
@@ -135,7 +135,7 @@ const char *kernel_get_module_path(const char *module)
 		if (dso__load_vmlinux(dso, map, vmlinux_name, NULL) <= 0)
 			return NULL;
 	} else {
-		if (dso__load_vmlinux_path(dso, map, NULL) < 0) {
+		if (dso__load_vmlinux_path(dso, map, NULL) <= 0) {
 			pr_debug("Failed to load kernel map.\n");
 			return NULL;
 		}
-- 
1.6.2.5


  parent reply	other threads:[~2010-12-12 15:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-12 15:16 [GIT PULL 0/2] perf/urgent fixes Arnaldo Carvalho de Melo
2010-12-12 15:16 ` [PATCH 1/2] perf probe: Fix use of kernel image path given by 'k' option Arnaldo Carvalho de Melo
2010-12-12 16:01   ` Masami Hiramatsu
2010-12-12 15:16 ` Arnaldo Carvalho de Melo [this message]
2010-12-12 16:02   ` [PATCH 2/2] perf symbols: Stop using vmlinux files with no symbols Masami Hiramatsu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1292167014-20936-3-git-send-email-acme@infradead.org \
    --to=acme@infradead.org \
    --cc=2nddept-manager@sdl.hitachi.co.jp \
    --cc=acme@redhat.com \
    --cc=fbuihuu@gmail.com \
    --cc=francis.moro@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=mingo@elte.hu \
    --cc=vagabon.xyz@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).