mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 17:13:52 +02:00
perf test: Don't fail if user rdpmc returns 0 when disabled
In certain hypervisor set ups the value 0 may be returned but this is only erroneous if the user rdpmc isn't disabled. Signed-off-by: Ian Rogers <irogers@google.com> Signed-off-by: Namhyung Kim <namhyung@kernel.org>
This commit is contained in:
parent
d3726d4e5b
commit
efee18981a
|
|
@ -322,7 +322,7 @@ static int test_stat_user_read(u64 event, enum user_read_state enabled)
|
|||
}
|
||||
|
||||
perf_evsel__read(evsel, 0, 0, &counts);
|
||||
if (counts.val == 0) {
|
||||
if (rdpmc_supported && counts.val == 0) {
|
||||
pr_err("User space counter reading for PMU %s [Failed read]\n", pmu->name);
|
||||
ret = TEST_FAIL;
|
||||
goto cleanup;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user