Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 234348
b: refs/heads/master
c: d2af968
h: refs/heads/master
v: v3
  • Loading branch information
Arnaldo Carvalho de Melo committed Jan 22, 2011
1 parent a863c12 commit 9d05478
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 915fce20ecf8f7ff4189d0fff42b62aebf6a57cc
refs/heads/master: d2af9687c96f3864178de1860e6d83873aeef224
8 changes: 5 additions & 3 deletions trunk/tools/perf/builtin-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,8 @@ static int test__open_syscall_event_on_all_cpus(void)
goto out_close_fd;
}

err = 0;

for (cpu = 0; cpu < cpus->nr; ++cpu) {
unsigned int expected;

Expand All @@ -416,18 +418,18 @@ static int test__open_syscall_event_on_all_cpus(void)

if (perf_evsel__read_on_cpu(evsel, cpu, 0) < 0) {
pr_debug("perf_evsel__open_read_on_cpu\n");
goto out_close_fd;
err = -1;
break;
}

expected = nr_open_calls + cpu;
if (evsel->counts->cpu[cpu].val != expected) {
pr_debug("perf_evsel__read_on_cpu: expected to intercept %d calls on cpu %d, got %" PRIu64 "\n",
expected, cpus->map[cpu], evsel->counts->cpu[cpu].val);
goto out_close_fd;
err = -1;
}
}

err = 0;
out_close_fd:
perf_evsel__close_fd(evsel, 1, threads->nr);
out_evsel_delete:
Expand Down

0 comments on commit 9d05478

Please sign in to comment.