testdisplay: automatically enable TEST_PLANES if possible
authorJesse Barnes <jbarnes@virtuousgeek.org>
Tue, 7 Jun 2011 20:32:37 +0000 (13:32 -0700)
committerJesse Barnes <jbarnes@virtuousgeek.org>
Tue, 7 Jun 2011 20:32:37 +0000 (13:32 -0700)
Just look for the ADDFB2 ioctl and enable the new code if it exists.

tests/testdisplay.c

index 8859d55..e8e3309 100644 (file)
 #include "xf86drmMode.h"
 #include "i915_drm.h"
 
+#ifdef DRM_IOCTL_MODE_ADDFB2
+#define TEST_PLANES 1
+#endif
+
 struct udev_monitor *uevent_monitor;
 drmModeRes *resources;
 int fd, modes;