All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH v2 04/10] tests/perf: rc6: try to guess when rc6 is disabled
Date: Wed, 23 Aug 2017 10:43:12 +0100	[thread overview]
Message-ID: <20170823094318.18966-5-lionel.g.landwerlin@intel.com> (raw)
In-Reply-To: <20170823094318.18966-1-lionel.g.landwerlin@intel.com>

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
---
 tests/perf.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/tests/perf.c b/tests/perf.c
index bc5ea133..1b441601 100644
--- a/tests/perf.c
+++ b/tests/perf.c
@@ -3445,6 +3445,17 @@ gen8_test_single_ctx_render_target_writes_a_counter(void)
 	} while (WEXITSTATUS(child_ret) == EAGAIN);
 }
 
+static bool
+rc6_enabled(void)
+{
+	char *rc6_status = read_debugfs_record(drm_fd, "i915_drpc_info",
+					       "RC6 Enabled");
+	bool enabled = strcmp(rc6_status, "yes") == 0;
+
+	free(rc6_status);
+	return enabled;
+}
+
 static void
 test_rc6_disable(void)
 {
@@ -3464,6 +3475,8 @@ test_rc6_disable(void)
 	};
 	uint64_t n_events_start, n_events_end;
 
+	igt_skip_on(!rc6_enabled());
+
 	stream_fd = __perf_open(drm_fd, &param);
 
 	n_events_start = read_debugfs_u64_record(drm_fd, "i915_drpc_info",
-- 
2.14.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2017-08-23  9:43 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-23  9:43 [PATCH v2 00/10] Improve robustness of the i915 perf tests Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 01/10] tests/perf: make stream_fd a global variable Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 02/10] tests/perf: add per context filtering test for gen8+ Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 03/10] tests/perf: update max buffer size for reading reports Lionel Landwerlin
2017-08-23  9:43 ` Lionel Landwerlin [this message]
2017-08-23  9:43 ` [PATCH v2 05/10] tests/perf: remove frequency related changes Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 06/10] tests/perf: rework oa-exponent test Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 07/10] tests/perf: make enable-disable more reliable Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 08/10] tests/perf: make buffer-fill " Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 09/10] tests/perf: add Kabylake support Lionel Landwerlin
2017-08-23  9:43 ` [PATCH v2 10/10] tests/perf: add Geminilake support Lionel Landwerlin
2017-08-28  7:21 ` [PATCH v2 00/10] Improve robustness of the i915 perf tests Arkadiusz Hiler
2017-08-28 13:33   ` Lionel Landwerlin
2017-08-28 14:23     ` Arkadiusz Hiler
2017-08-29  8:54       ` Lionel Landwerlin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170823094318.18966-5-lionel.g.landwerlin@intel.com \
    --to=lionel.g.landwerlin@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.