[igt-dev] [PATCH i-g-t] lib: Remove incomplete assert from igt_require_fb_modifiers()

Chris Wilson chris at chris-wilson.co.uk
Wed Oct 3 19:56:00 UTC 2018


Since the igt_assert is far from complete and does not enumerate all the
possible valid values, restrict the function to do only what it says it
will do, check for the required fb modifiers.

Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
---
 lib/ioctl_wrappers.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/lib/ioctl_wrappers.c b/lib/ioctl_wrappers.c
index 5ad682f5..529eae36 100644
--- a/lib/ioctl_wrappers.c
+++ b/lib/ioctl_wrappers.c
@@ -1667,7 +1667,6 @@ void igt_require_fb_modifiers(int fd)
 		int ret;
 
 		ret = drmGetCap(fd, DRM_CAP_ADDFB2_MODIFIERS, &cap_modifiers);
-		igt_assert(ret == 0 || errno == EINVAL);
 		has_modifiers = ret == 0 && cap_modifiers == 1;
 		cap_modifiers_tested = true;
 	}
-- 
2.19.0



More information about the igt-dev mailing list