[igt-dev] [PATCH i-g-t] tests/kms_available_modes_crc: Enable test for ARGB888/ABGR8888

Kulkarni, Vandita vandita.kulkarni at intel.com
Fri Jun 22 07:46:28 UTC 2018



> -----Original Message-----
> From: Lankhorst, Maarten
> Sent: Thursday, June 21, 2018 11:54 PM
> To: igt-dev at lists.freedesktop.org; Kulkarni, Vandita
> <vandita.kulkarni at intel.com>
> Subject: Re: [PATCH i-g-t] tests/kms_available_modes_crc: Enable test for
> ARGB888/ABGR8888
> 
> Hey,
> 
> tor 2018-06-21 klockan 19:02 +0530 skrev Vandita Kulkarni:
> > icl onwards hw supports bypass for 0xff and 0x00 per-pixel alpha,
> > fixing the crc mismatch problem.
> > Hence enabling this test for ARGB8888/ABGR8888 format planes.
> >
> > Signed-off-by: Vandita Kulkarni <vandita.kulkarni at intel.com>
> > ---
> >  tests/kms_available_modes_crc.c | 26 +++++++++++++-------------
> >  1 file changed, 13 insertions(+), 13 deletions(-)
> >
> > diff --git a/tests/kms_available_modes_crc.c
> > b/tests/kms_available_modes_crc.c
> > index b70ef5d..2c6f707 100644
> > --- a/tests/kms_available_modes_crc.c
> > +++ b/tests/kms_available_modes_crc.c
> > @@ -143,7 +143,7 @@ static const struct {
> >  	 * and getting crc is skipped.
> >  	 */
> >  	{ DRM_FORMAT_ARGB8888, 0, SKIP4, 0xffffffff},
> > -	{ DRM_FORMAT_ABGR8888, 0, SKIP4, 0x00ffffff},
> > +	{ DRM_FORMAT_ABGR8888, 0, SKIP4, 0xffffffff},
> >
> >  	{ DRM_FORMAT_XRGB2101010, 0, BYTES_PP_4, 0xffffffff},
> >  	{ DRM_FORMAT_XBGR2101010, 0, BYTES_PP_4, 0xffffffff},
> > @@ -223,21 +223,21 @@ static bool fill_in_fb(data_t *data,
> > igt_output_t *output, igt_plane_t *plane,
> >  		writesize = data->size+data->size/2;
> >  		break;
> >  	case SKIP4:
> > -		if (fillers[i].fourcc == DRM_FORMAT_ARGB8888 &&
> > -		    plane->type == DRM_PLANE_TYPE_CURSOR) {
> > +		ptemp_32_buf = (unsigned int *)data->buf;
> > +		for (c = 0; c < data->size/4; c++)
> > +			ptemp_32_buf[c] = fillers[i].value;
> > +		writesize = data->size;
> >  		/*
> > -		 * special for cursor plane where blending works
> > correctly.
> > +		 * HW WA to fix per-pixel alpha 0x00 and 0xff
> > +		 * on non cursor planes is icl onwards only.
> >  		 */
> > -			ptemp_32_buf = (unsigned int*)data->buf;
> > -			for (c = 0; c < data->size/4; c++)
> > -				ptemp_32_buf[c] = fillers[i].value;
> > -			writesize = data->size;
> > -			break;
> > +		if ((intel_gen(intel_get_drm_devid(data->gfx_fd)) <
> > 11) &&
> > +			plane->type != DRM_PLANE_TYPE_CURSOR) {
> > +			igt_info("Format %s CRC comparison skipped
> > by design.\n",
> > +				 (char *)&fillers[i].fourcc);
> > +			return false;
> >  		}
> > -		igt_info("Format %s CRC comparison skipped by
> > design.\n",
> > -			 (char*)&fillers[i].fourcc);
> > -
> > -		return false;
> > +		break;
> >  	default:
> >  		igt_info("Unsupported mode for test %s\n",
> >  			 (char*)&fillers[i].fourcc);
> Could we only blacklist gen9 and gen10? Earlier platforms should handle
> alpha correctly.
> 
Sure, will submit the next version with this change.
Thanks
Vandita 
> ~Maarten


More information about the igt-dev mailing list