summaryrefslogtreecommitdiff
path: root/lib/ioctl_wrappers.h
diff options
context:
space:
mode:
authorAndi Shyti <andi.shyti@intel.com>2019-04-05 04:07:32 +0300
committerChris Wilson <chris@chris-wilson.co.uk>2019-04-05 08:58:58 +0100
commit019f892e5d1a0a9643cb726c47ce2d99c14b444f (patch)
tree3026e83febdee0f9b1885d7d7591ab2b0061bbc6 /lib/ioctl_wrappers.h
parent2f38eabf06ec5bcdf28e1bfd0ffd95581b20e26b (diff)
lib: ioctl_wrappers: reach engines by index as well
With the new engine query method engines are reachable through an index and context they are combined with. The 'gem_has_ring()' becomes 'gem_context_has_engine()' that requires the index that the engine is mapped within the driver. The function has been moved from lib/ioctl_wappers to lib/i915/gem_context where it is more appropriate. The previous 'gem_has_ring()' function becomes a wrapper to the new 'gem_context_has_engine()'. Signed-off-by: Andi Shyti <andi.shyti@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Diffstat (limited to 'lib/ioctl_wrappers.h')
-rw-r--r--lib/ioctl_wrappers.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/ioctl_wrappers.h b/lib/ioctl_wrappers.h
index f0be2608..03211c97 100644
--- a/lib/ioctl_wrappers.h
+++ b/lib/ioctl_wrappers.h
@@ -142,11 +142,12 @@ bool gem_has_exec_fence(int fd);
/* check functions which auto-skip tests by calling igt_skip() */
void gem_require_caching(int fd);
-bool gem_has_ring(int fd, unsigned ring);
void gem_require_ring(int fd, unsigned ring);
bool gem_has_mocs_registers(int fd);
void gem_require_mocs_registers(int fd);
+#define gem_has_ring(f, r) gem_context_has_engine(f, 0, r)
+
/* prime */
struct local_dma_buf_sync {
uint64_t flags;