diff options
-rw-r--r-- | tests/util/piglit-framework-gl/piglit_drm_dma_buf.c | 15 | ||||
-rw-r--r-- | tests/util/piglit-framework-gl/piglit_drm_dma_buf.h | 17 |
2 files changed, 17 insertions, 15 deletions
diff --git a/tests/util/piglit-framework-gl/piglit_drm_dma_buf.c b/tests/util/piglit-framework-gl/piglit_drm_dma_buf.c index a0a2fc42f..c3225c399 100644 --- a/tests/util/piglit-framework-gl/piglit_drm_dma_buf.c +++ b/tests/util/piglit-framework-gl/piglit_drm_dma_buf.c @@ -40,21 +40,6 @@ #include <drm.h> #include <unistd.h> -/* These definitions were added in libdrm 2.4.68, since that's still pretty - * recent defined these to allow older libdrm to continue working. - */ -#ifndef DRM_FORMAT_R8 -#define DRM_FORMAT_R8 fourcc_code('R', '8', ' ', ' ') -#endif - -#ifndef DRM_FORMAT_RG88 -#define DRM_FORMAT_RG88 fourcc_code('R', 'G', '8', '8') -#endif - -#ifndef DRM_FORMAT_GR88 -#define DRM_FORMAT_GR88 fourcc_code('G', 'R', '8', '8') -#endif - #define ALIGN(value, alignment) (((value) + alignment - 1) & ~(alignment - 1)) struct piglit_drm_driver { diff --git a/tests/util/piglit-framework-gl/piglit_drm_dma_buf.h b/tests/util/piglit-framework-gl/piglit_drm_dma_buf.h index 5872df93c..36777a835 100644 --- a/tests/util/piglit-framework-gl/piglit_drm_dma_buf.h +++ b/tests/util/piglit-framework-gl/piglit_drm_dma_buf.h @@ -23,6 +23,23 @@ #ifndef PIGLIT_DRM_DMA_BUF_H #define PIGLIT_DRM_DMA_BUF_H +#include "drm_fourcc.h" + +/* These definitions were added in libdrm 2.4.68, since that's still pretty + * recent defined these to allow older libdrm to continue working. + */ +#ifndef DRM_FORMAT_R8 +#define DRM_FORMAT_R8 fourcc_code('R', '8', ' ', ' ') +#endif + +#ifndef DRM_FORMAT_RG88 +#define DRM_FORMAT_RG88 fourcc_code('R', 'G', '8', '8') +#endif + +#ifndef DRM_FORMAT_GR88 +#define DRM_FORMAT_GR88 fourcc_code('G', 'R', '8', '8') +#endif + struct piglit_dma_buf { unsigned w; unsigned h; |