All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] perf: Do not require /lib/modules/* on a guest
@ 2013-07-15 20:27 Jason Wessel
  2013-07-29 22:40 ` David Ahern
  2013-08-12 10:24 ` [tip:perf/core] perf machine: Do not require /lib/modules/ * " tip-bot for Jason Wessel
  0 siblings, 2 replies; 3+ messages in thread
From: Jason Wessel @ 2013-07-15 20:27 UTC (permalink / raw)
  To: a.p.zijlstra; +Cc: paulus, acme, linux-kernel

For some types of work loads and special guest environments, you might
have a kernel that has no kernel modules.  The perf kvm record tool
fails instantiate vmlinux maps when the kernel modules directory
cannot be opened, even though the kallsyms has been properly
processed.  This leads to a perf kvm report that has no guest symbols
resolved.

This patch changes the failure to locate kernel modules to be
non-fatal.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
---
 tools/perf/util/machine.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.c
index b2ecad6..eb9ebd6 100644
--- a/tools/perf/util/machine.c
+++ b/tools/perf/util/machine.c
@@ -808,7 +808,10 @@ static int machine__create_modules(struct machine *machine)
 	free(line);
 	fclose(file);
 
-	return machine__set_modules_path(machine);
+	if (machine__set_modules_path(machine) < 0) {
+		pr_debug("Problems setting modules path maps, continuing anyway...\n");
+	}
+	return 0;
 
 out_delete_line:
 	free(line);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-08-12 10:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-15 20:27 [PATCH] perf: Do not require /lib/modules/* on a guest Jason Wessel
2013-07-29 22:40 ` David Ahern
2013-08-12 10:24 ` [tip:perf/core] perf machine: Do not require /lib/modules/ * " tip-bot for Jason Wessel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.