diff options
author | Imre Deak <imre.deak@intel.com> | 2013-05-28 17:22:57 +0300 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-05-28 18:32:29 +0200 |
commit | a3b47dbe69deebcaf353876feaefa105136dad05 (patch) | |
tree | 20ae7be0aa93210358b01183e485b8e9f9cce47c /lib | |
parent | 55876338fa2bc37f632a8ca970b3573541cacc38 (diff) |
lib: make sure all rings are idle in gpu_quiescent_gpu()
Signed-off-by: Imre Deak <imre.deak@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/drmtest.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/drmtest.c b/lib/drmtest.c index 16f5be1f..2d37fb6c 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -109,6 +109,7 @@ int gem_available_fences(int fd) } +#define LOCAL_I915_EXEC_VEBOX (4 << 0) /* Ensure the gpu is idle by launching a nop execbuf and stalling for it. */ void gem_quiescent_gpu(int fd) { @@ -143,6 +144,21 @@ void gem_quiescent_gpu(int fd) do_ioctl(fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf); + if (gem_has_blt(fd)) { + execbuf.flags = I915_EXEC_BLT; + do_ioctl(fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf); + } + + if (gem_has_bsd(fd)) { + execbuf.flags = I915_EXEC_BSD; + do_ioctl(fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf); + } + + if (gem_has_vebox(fd)) { + execbuf.flags = LOCAL_I915_EXEC_VEBOX; + do_ioctl(fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf); + } + gem_sync(fd, handle); } |