diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/util/probe-event.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index a372d748644b..f0223166e761 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c | |||
@@ -510,18 +510,18 @@ int show_available_vars(struct perf_probe_event *pevs, int npevs, | |||
510 | if (ret < 0) | 510 | if (ret < 0) |
511 | return ret; | 511 | return ret; |
512 | 512 | ||
513 | fd = open_vmlinux(module); | ||
514 | if (fd < 0) { | ||
515 | pr_warning("Failed to open debug information file.\n"); | ||
516 | return fd; | ||
517 | } | ||
518 | |||
519 | setup_pager(); | 513 | setup_pager(); |
520 | 514 | ||
521 | for (i = 0; i < npevs && ret >= 0; i++) | 515 | for (i = 0; i < npevs && ret >= 0; i++) { |
516 | fd = open_vmlinux(module); | ||
517 | if (fd < 0) { | ||
518 | pr_warning("Failed to open debug information file.\n"); | ||
519 | ret = fd; | ||
520 | break; | ||
521 | } | ||
522 | ret = show_available_vars_at(fd, &pevs[i], max_vls, _filter, | 522 | ret = show_available_vars_at(fd, &pevs[i], max_vls, _filter, |
523 | externs); | 523 | externs); |
524 | 524 | } | |
525 | return ret; | 525 | return ret; |
526 | } | 526 | } |
527 | 527 | ||