From: Antonio Argenziano <antonio.argenziano@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [Intel-gfx] [PATCH i-g-t] lib: Don't specify a non-existent blitter ring
Date: Tue, 18 Feb 2020 10:08:13 -0800 [thread overview]
Message-ID: <5ad6c04e-4dc5-8dfd-fc0f-7a9e68dbd591@intel.com> (raw)
In-Reply-To: <20200218144702.1270825-1-chris@chris-wilson.co.uk>
On 18/02/20 06:47, Chris Wilson wrote:
> I915_EXEC_BLT only exists on gen6+
>
> Closes: https://gitlab.freedesktop.org/drm/intel/issues/1256
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Acked-by: Antonio Argenziano <antonio.argenziano@intel.com>
> ---
> lib/intel_batchbuffer.c | 23 ++++++++---------------
> 1 file changed, 8 insertions(+), 15 deletions(-)
>
> diff --git a/lib/intel_batchbuffer.c b/lib/intel_batchbuffer.c
> index 5a00481cf..f1a45b473 100644
> --- a/lib/intel_batchbuffer.c
> +++ b/lib/intel_batchbuffer.c
> @@ -695,20 +695,13 @@ fill_object(struct drm_i915_gem_exec_object2 *obj, uint32_t gem_handle,
>
> static void exec_blit(int fd,
> struct drm_i915_gem_exec_object2 *objs, uint32_t count,
> - uint32_t batch_len /* in dwords */)
> + int gen)
> {
> - struct drm_i915_gem_execbuffer2 exec;
> -
> - exec.buffers_ptr = to_user_pointer(objs);
> - exec.buffer_count = count;
> - exec.batch_start_offset = 0;
> - exec.batch_len = batch_len * 4;
> - exec.DR1 = exec.DR4 = 0;
> - exec.num_cliprects = 0;
> - exec.cliprects_ptr = 0;
> - exec.flags = I915_EXEC_BLT;
> - i915_execbuffer2_set_context_id(exec, 0);
> - exec.rsvd2 = 0;
> + struct drm_i915_gem_execbuffer2 exec = {
> + .buffers_ptr = to_user_pointer(objs),
> + .buffer_count = count,
> + .flags = gen >= 6 ? I915_EXEC_BLT : 0,
> + };
>
> gem_execbuf(fd, &exec);
> }
> @@ -892,7 +885,7 @@ void igt_blitter_src_copy(int fd,
> objs[0].flags |= EXEC_OBJECT_NEEDS_FENCE;
> objs[1].flags |= EXEC_OBJECT_NEEDS_FENCE;
>
> - exec_blit(fd, objs, 3, ARRAY_SIZE(batch));
> + exec_blit(fd, objs, 3, gen);
>
> gem_close(fd, batch_handle);
> }
> @@ -985,7 +978,7 @@ void igt_blitter_fast_copy__raw(int fd,
> fill_object(&objs[1], src_handle, NULL, 0);
> fill_object(&objs[2], batch_handle, relocs, 2);
>
> - exec_blit(fd, objs, 3, ARRAY_SIZE(batch));
> + exec_blit(fd, objs, 3, intel_gen(intel_get_drm_devid(fd)));
>
> gem_close(fd, batch_handle);
> }
>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next prev parent reply other threads:[~2020-02-18 18:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-18 14:47 [Intel-gfx] [PATCH i-g-t] lib: Don't specify a non-existent blitter ring Chris Wilson
2020-02-18 18:08 ` Antonio Argenziano [this message]
2020-02-18 19:44 ` [igt-dev] ✗ Fi.CI.BAT: failure for " Patchwork
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=5ad6c04e-4dc5-8dfd-fc0f-7a9e68dbd591@intel.com \
--to=antonio.argenziano@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=igt-dev@lists.freedesktop.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox