[PATCH i-g-t] lib/igt_draw: Don't call i915 specific ioctls on xe in draw rectangle
Zbigniew Kempczyński
zbigniew.kempczynski at intel.com
Thu Feb 22 13:18:03 UTC 2024
We've been observing annoying warnings in kernel log during executing
drawing rectangle on xe like:
Ioctl argument check failed at drivers/gpu/drm/xe/xe_exec_queue.c:676:
!len || len > XE_HW_ENGINE_MAX_INSTANCE
If ioctl() specific to the driver needs to be executed it should be
protected by conditional is_i915_device() or is_xe_device(). Add
such condition for i915 what fixes above issue.
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
Cc: Vandita Kulkarni <vandita.kulkarni at intel.com>
---
lib/igt_draw.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/igt_draw.c b/lib/igt_draw.c
index 0757e9801b..1b702e376d 100644
--- a/lib/igt_draw.c
+++ b/lib/igt_draw.c
@@ -882,7 +882,7 @@ void igt_draw_rect(int fd, struct buf_ops *bops, uint32_t ctx,
};
swizzle = I915_BIT_6_SWIZZLE_NONE;
- if (tiling != I915_TILING_NONE && gem_available_fences(fd)) {
+ if (is_i915_device(fd) && tiling != I915_TILING_NONE && gem_available_fences(fd)) {
gem_get_tiling(fd, buf_handle, &buf_tiling, &swizzle);
igt_assert(tiling == buf_tiling);
}
--
2.34.1
More information about the igt-dev
mailing list