From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915/selftests: Add the mock engine to the gt->engine[]
Date: Fri, 18 Oct 2019 14:22:39 +0100 [thread overview]
Message-ID: <33e779c8-1085-6edd-7136-d8213ec30711@linux.intel.com> (raw)
In-Reply-To: <20191018130703.31125-1-chris@chris-wilson.co.uk>
On 18/10/2019 14:07, Chris Wilson wrote:
> Remember to include the newly created mock engine in the list of
> available engines inside the gt.
>
> Fixes: a50134b1983b ("drm/i915: Make for_each_engine_masked work on intel_gt")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wi..oh wait!^W^W^W :)
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Regards,
Tvrtko
> ---
> drivers/gpu/drm/i915/gt/mock_engine.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/gt/mock_engine.c b/drivers/gpu/drm/i915/gt/mock_engine.c
> index 747f7c7790eb..123db2c3f956 100644
> --- a/drivers/gpu/drm/i915/gt/mock_engine.c
> +++ b/drivers/gpu/drm/i915/gt/mock_engine.c
> @@ -253,6 +253,7 @@ struct intel_engine_cs *mock_engine(struct drm_i915_private *i915,
> snprintf(engine->base.name, sizeof(engine->base.name), "%s", name);
> engine->base.id = id;
> engine->base.mask = BIT(id);
> + engine->base.legacy_idx = INVALID_ENGINE;
> engine->base.instance = id;
> engine->base.status_page.addr = (void *)(engine + 1);
>
> @@ -267,6 +268,9 @@ struct intel_engine_cs *mock_engine(struct drm_i915_private *i915,
> engine->base.reset.finish = mock_reset_finish;
> engine->base.cancel_requests = mock_cancel_requests;
>
> + i915->gt.engine[id] = &engine->base;
> + i915->gt.engine_class[0][id] = &engine->base;
> +
> /* fake hw queue */
> spin_lock_init(&engine->hw_lock);
> timer_setup(&engine->hw_delay, hw_delay_complete, 0);
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2019-10-18 13:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-18 13:07 [PATCH] drm/i915/selftests: Add the mock engine to the gt->engine[] Chris Wilson
2019-10-18 13:22 ` Tvrtko Ursulin [this message]
2019-10-18 13:25 ` Chris Wilson
2019-10-18 16:17 ` ✗ Fi.CI.BAT: failure for " Patchwork
2019-10-21 9:15 ` [Intel-gfx] [PATCH] " kbuild test robot
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=33e779c8-1085-6edd-7136-d8213ec30711@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=chris@chris-wilson.co.uk \
--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.