[Piglit] [PATCH piglit 1/2] make sure 'unsupported format' test always uses an unsupported format

Lionel Landwerlin lionel.g.landwerlin at intel.com
Fri Nov 30 15:29:05 UTC 2018


On 30/11/2018 13:58, Eric Engestrom wrote:
> Instead of using the fact this one driver currently doesn't support this
> one format, let's just use a format that will never be supported by
> anyone.


Maybe put it in tests/util/piglit-framework-gl/piglit_drm_dma_buf.h ?


> Signed-off-by: Eric Engestrom <eric.engestrom at intel.com>
> ---
>   .../ext_image_dma_buf_import/intel_unsupported_format.c    | 7 ++++++-
>   1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/tests/spec/ext_image_dma_buf_import/intel_unsupported_format.c b/tests/spec/ext_image_dma_buf_import/intel_unsupported_format.c
> index 8373e903891a3865dd65..448274a48aa765a9ee98 100644
> --- a/tests/spec/ext_image_dma_buf_import/intel_unsupported_format.c
> +++ b/tests/spec/ext_image_dma_buf_import/intel_unsupported_format.c
> @@ -41,13 +41,18 @@ PIGLIT_GL_TEST_CONFIG_BEGIN
>   
>   PIGLIT_GL_TEST_CONFIG_END
>   
> +/* added in libdrm 2.4.95 */
> +#ifndef DRM_FORMAT_INVALID
> +#define DRM_FORMAT_INVALID 0
> +#endif
> +
>   static EGLImageKHR
>   create_image(unsigned w, unsigned h, int fd, unsigned stride, unsigned offset)
>   {
>   	EGLint attr[] = {
>   		EGL_WIDTH, w,
>   		EGL_HEIGHT, h,
> -		EGL_LINUX_DRM_FOURCC_EXT, DRM_FORMAT_RGB332,
> +		EGL_LINUX_DRM_FOURCC_EXT, DRM_FORMAT_INVALID,
>   		EGL_DMA_BUF_PLANE0_FD_EXT, fd,
>   		EGL_DMA_BUF_PLANE0_OFFSET_EXT, offset,
>   		EGL_DMA_BUF_PLANE0_PITCH_EXT, stride,




More information about the Piglit mailing list