Commit 6a15ccfb authored by Chris Wilson's avatar Chris Wilson 🤔

igt/perf_pmu: Tidy skip message for unsupported kernels

Use a more compact expression to detect when the kernel doesn't support
perf.
Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin's avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
parent e2d80575
......@@ -51,7 +51,7 @@ static int open_pmu(uint64_t config)
int fd;
fd = perf_i915_open(config);
igt_require(fd >= 0 || (fd < 0 && errno != ENODEV));
igt_skip_on(fd < 0 && errno == ENODEV);
igt_assert(fd >= 0);
return fd;
......@@ -62,7 +62,7 @@ static int open_group(uint64_t config, int group)
int fd;
fd = perf_i915_open_group(config, group);
igt_require(fd >= 0 || (fd < 0 && errno != ENODEV));
igt_skip_on(fd < 0 && errno == ENODEV);
igt_assert(fd >= 0);
return fd;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment