[igt-dev] [PATCH v8 02/16] fb: Only set the GEM domain on intel platforms
Maxime Ripard
maxime.ripard at bootlin.com
Thu Oct 4 12:38:55 UTC 2018
The gem_set_domain call uses an i915 specific ioctl that will fail on
anything else. Let's move that call under a check for whether or not we're
running on an intel platform.
Signed-off-by: Maxime Ripard <maxime.ripard at bootlin.com>
---
lib/igt_fb.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index f1332169915f..aaa90bf74a9a 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -1356,8 +1356,9 @@ static void *map_bo(int fd, struct igt_fb *fb)
{
void *ptr;
- gem_set_domain(fd, fb->gem_handle,
- I915_GEM_DOMAIN_GTT, I915_GEM_DOMAIN_GTT);
+ if (is_i915_device(fd))
+ gem_set_domain(fd, fb->gem_handle,
+ I915_GEM_DOMAIN_GTT, I915_GEM_DOMAIN_GTT);
if (fb->is_dumb)
ptr = kmstest_dumb_map_buffer(fd, fb->gem_handle, fb->size,
--
git-series 0.9.1
More information about the igt-dev
mailing list