All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ashutosh Dixit <ashutosh.dixit@intel.com>
To: igt-dev@lists.freedesktop.org
Subject: [igt-dev] [PATCH i-g-t] i915/gem_spin_batch: Use __for_each_physical_engine
Date: Fri,  8 May 2020 17:21:24 -0700	[thread overview]
Message-ID: <20200509002124.3174-1-ashutosh.dixit@intel.com> (raw)

Instead of the legacy for_each_physical_engine use
__for_each_physical_engine to utilize all engines.

Fixes: 57efd81037 ("i915/gem_spin_batch: Add test to execute in parallel on all engines")
Signed-off-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
---
 tests/i915/gem_spin_batch.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tests/i915/gem_spin_batch.c b/tests/i915/gem_spin_batch.c
index e7dd58ec2..6a7753ced 100644
--- a/tests/i915/gem_spin_batch.c
+++ b/tests/i915/gem_spin_batch.c
@@ -137,10 +137,11 @@ static void spin_on_all_engines(int fd, unsigned int timeout_sec)
 static void spin_all(int i915, unsigned int flags)
 #define PARALLEL_SPIN_NEW_CTX BIT(0)
 {
+	const struct intel_execution_engine2 *e2;
 	struct igt_spin *spin, *n;
 	IGT_LIST_HEAD(list);
 
-	for_each_physical_engine(e, i915) {
+	__for_each_physical_engine(i915, e2) {
 		uint32_t ctx;
 
 		ctx = 0;
@@ -150,7 +151,7 @@ static void spin_all(int i915, unsigned int flags)
 		/* Prevent preemption so only one is allowed on each engine */
 		spin = igt_spin_new(i915,
 				    .ctx = ctx,
-				    .engine = eb_ring(e),
+				    .engine = e2->flags,
 				    .flags = (IGT_SPIN_POLL_RUN |
 					      IGT_SPIN_NO_PREEMPTION));
 		if (ctx)
-- 
2.26.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

             reply	other threads:[~2020-05-09  0:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-09  0:21 Ashutosh Dixit [this message]
2020-05-09  1:05 ` [igt-dev] ✓ Fi.CI.BAT: success for i915/gem_spin_batch: Use __for_each_physical_engine Patchwork
2020-05-09  2:14 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2020-05-09  8:21 ` [igt-dev] [PATCH i-g-t] " Chris Wilson
2020-05-09  8:23 ` Chris Wilson

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=20200509002124.3174-1-ashutosh.dixit@intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=igt-dev@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.