summaryrefslogtreecommitdiff
path: root/tests/gem_exec_flush.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2016-05-02 18:55:24 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2016-05-02 18:57:03 +0100
commitd9025d3298d8cb647b754e7f5d5e95e3dca67244 (patch)
tree3c18dc3d8f4bde9aa86f84747c9d85f7e86f5faf /tests/gem_exec_flush.c
parent22e6157d383c5fe1115ed05aab3909c77feb8856 (diff)
igt/gem_exec_flush: Match gem_set_domain to pointer access
When using the kernel set-domain cache management, we need to set the domain as appropriate for our pointer access. In this case we access the buffer through a CPU mmap, and so we must request access via the CPU domain. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests/gem_exec_flush.c')
-rw-r--r--tests/gem_exec_flush.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/gem_exec_flush.c b/tests/gem_exec_flush.c
index 326cafa7..1b5172c6 100644
--- a/tests/gem_exec_flush.c
+++ b/tests/gem_exec_flush.c
@@ -167,8 +167,8 @@ overwrite:
if (flags & SET_DOMAIN) {
igt_interruptible(flags & INTERRUPTIBLE)
gem_set_domain(fd, obj[0].handle,
- I915_GEM_DOMAIN_GTT,
- (flags & WRITE) ? I915_GEM_DOMAIN_GTT : 0);
+ I915_GEM_DOMAIN_CPU,
+ (flags & WRITE) ? I915_GEM_DOMAIN_CPU : 0);
if (xor)
igt_assert_eq_u32(map[i], i ^ 0xffffffff);