From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Antonio Argenziano <antonio.argenziano@intel.com>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t] tests/i915/gem_exec_basic: Skip subtest gtt if gtt mapping is unavailable
Date: Thu, 30 Jan 2020 21:05:38 -0800 [thread overview]
Message-ID: <87lfpo5i71.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20200131001516.2228-1-antonio.argenziano@intel.com>
On Thu, 30 Jan 2020 16:15:16 -0800, Antonio Argenziano wrote:
>
> The subtest tries to do a gtt mapping but if there is no mappable
> aperture that is not possible.
>
> Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
> ---
> tests/i915/gem_exec_basic.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tests/i915/gem_exec_basic.c b/tests/i915/gem_exec_basic.c
> index 70dce34b..08336168 100644
> --- a/tests/i915/gem_exec_basic.c
> +++ b/tests/i915/gem_exec_basic.c
> @@ -93,6 +93,7 @@ static void gtt(int fd, uint64_t flags)
> struct drm_i915_gem_exec_object2 *exec;
> uint32_t handle;
>
> + gem_require_mappable_ggtt(fd);
> gem_require_ring(fd, flags);
>
> handle = gem_create(fd, 4096);
Since the test is not really using any tiling features of the ggtt perhaps
no need to skip? Instead how about this:
diff --git a/tests/i915/gem_exec_basic.c b/tests/i915/gem_exec_basic.c
index 70dce34b5..73921c1b3 100644
--- a/tests/i915/gem_exec_basic.c
+++ b/tests/i915/gem_exec_basic.c
@@ -98,7 +98,10 @@ static void gtt(int fd, uint64_t flags)
handle = gem_create(fd, 4096);
gem_set_domain(fd, handle, I915_GEM_DOMAIN_GTT, I915_GEM_DOMAIN_GTT);
- execbuf = gem_mmap__gtt(fd, handle, 4096, PROT_WRITE);
+ if (gem_has_mappable_ggtt(fd))
+ execbuf = gem_mmap__gtt(fd, handle, 4096, PROT_WRITE);
+ else
+ execbuf = gem_mmap__device_coherent(fd, handle, 0, 4096, PROT_WRITE);
exec = (struct drm_i915_gem_exec_object2 *)(execbuf + 1);
gem_close(fd, 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-01-31 5:25 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-31 0:15 [igt-dev] [PATCH i-g-t] tests/i915/gem_exec_basic: Skip subtest gtt if gtt mapping is unavailable Antonio Argenziano
2020-01-31 0:54 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2020-01-31 5:05 ` Dixit, Ashutosh [this message]
2020-01-31 8:20 ` [igt-dev] [PATCH i-g-t] " Chris Wilson
2020-01-31 10:50 ` Petri Latvala
2020-01-31 10:56 ` Chris Wilson
2020-02-02 21:34 ` [igt-dev] ✓ Fi.CI.IGT: success for " Patchwork
-- strict thread matches above, loose matches on Subject: below --
2020-01-31 17:04 [igt-dev] [PATCH i-g-t] " Antonio Argenziano
2020-02-01 3:38 ` Dixit, Ashutosh
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=87lfpo5i71.wl-ashutosh.dixit@intel.com \
--to=ashutosh.dixit@intel.com \
--cc=antonio.argenziano@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.