[igt-dev] [PATCH v7 09/14] fb: Add more formats

Maxime Ripard maxime.ripard at bootlin.com
Tue Sep 25 07:49:43 UTC 2018


On Wed, Sep 19, 2018 at 04:14:22PM +0300, Ville Syrjälä wrote:
> On Tue, Sep 11, 2018 at 10:47:36AM +0200, Maxime Ripard wrote:
> > We're going to need some DRM formats, and we're going to need the igt_fb
> > code to handle them. Since it relies on the format_desc structure to map
> > the DRM fourcc to the pixman and cairo formats, we need to add these new
> > formats to that structure.
> > 
> > Reviewed-by: Eric Anholt <eric at anholt.net>
> > Signed-off-by: Maxime Ripard <maxime.ripard at bootlin.com>
> > ---
> >  lib/igt_fb.c | 35 +++++++++++++++++++++++++++++++++++
> >  1 file changed, 35 insertions(+)
> > 
> > diff --git a/lib/igt_fb.c b/lib/igt_fb.c
> > index f83ad0d2679c..425f98e23380 100644
> > --- a/lib/igt_fb.c
> > +++ b/lib/igt_fb.c
> > @@ -72,16 +72,46 @@ static struct format_desc_struct {
> >  	int num_planes;
> >  	int plane_bpp[4];
> >  } format_desc[] = {
> > +	{ .name = "ARGB1555", .depth = 16, .drm_id = DRM_FORMAT_ARGB1555,
> > +	  .cairo_id = CAIRO_FORMAT_INVALID,
> > +	  .pixman_id = PIXMAN_a1r5g5b5,
> > +	  .num_planes = 1, .plane_bpp = { 16, },
> > +	},
> > +	{ .name = "XRGB1555", .depth = 15, .drm_id = DRM_FORMAT_XRGB1555,
> > +	  .cairo_id = CAIRO_FORMAT_INVALID,
> > +	  .pixman_id = PIXMAN_x1r5g5b5,
> > +	  .num_planes = 1, .plane_bpp = { 16, },
> > +	},
> 
> I think this is going to mess up the depth->format behaviour that
> bunch of tests expect. So nak on adding .depth to these.

What is your suggestion then?

Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/igt-dev/attachments/20180925/e43c37ac/attachment.sig>


More information about the igt-dev mailing list