summaryrefslogtreecommitdiff
path: root/tests/gem_ringfill.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2017-02-03 21:57:33 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2017-02-03 21:08:03 +0000
commitee6a40fd01871b79a391646e15ce76bd9d5c1138 (patch)
tree75d2ffffa9baa7cbd64c10a040014ce3d3982b82 /tests/gem_ringfill.c
parentba0d1dcb2b6e6a5ec6cb1645988df7c8eccec5c3 (diff)
igt: Skip MI_STORE_DWORD_IMM on gen2
On gen2 MI_STORE_DWORD_IMM operates on a physical, not virtual, address i.e. we can't use it. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests/gem_ringfill.c')
-rw-r--r--tests/gem_ringfill.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/gem_ringfill.c b/tests/gem_ringfill.c
index e47dbbb5..74bb0a10 100644
--- a/tests/gem_ringfill.c
+++ b/tests/gem_ringfill.c
@@ -230,6 +230,11 @@ static void run_test(int fd, unsigned ring, unsigned flags)
run_test(fd, ring, 0);
}
+static bool can_store_dword_imm(int fd)
+{
+ return intel_gen(intel_gen(intel_get_drm_devid(fd))) > 2;
+}
+
igt_main
{
const struct {
@@ -256,6 +261,7 @@ igt_main
int gen;
fd = drm_open_driver(DRIVER_INTEL);
+ igt_require(can_store_dword_imm(fd));
gen = intel_gen(intel_get_drm_devid(fd));
if (gen > 3 && gen < 6) { /* ctg and ilk need secure batches */
igt_require(drmSetMaster(fd) == 0);