Re: [PATCH v3 7/8] drm/sun4i: dsi: Add burst support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Feb 13, 2019 at 03:36:48PM +0100, Paul Kocialkowski wrote:
> Hi,
> 
> On Mon, 2019-02-11 at 15:41 +0100, Maxime Ripard wrote:
> > From: Konstantin Sudakov <k.sudakov@xxxxxxxxxxxxxxxxxx>
> > 
> > The current driver doesn't support the DSI burst operation mode.
> > 
> > Let's add the needed quirks to make it work.
> > 
> > Signed-off-by: Konstantin Sudakov <k.sudakov@xxxxxxxxxxxxxxxxxx>
> > Signed-off-by: Maxime Ripard <maxime.ripard@xxxxxxxxxxx>
> > ---
> >  drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c | 171 ++++++++++++++++++++------
> >  1 file changed, 132 insertions(+), 39 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
> > index e0288e7dc64e..4cb715dc9100 100644
> > --- a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
> > +++ b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
> 
> [...]
> 
> > @@ -457,52 +531,71 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,
> >  	struct mipi_dsi_device *device = dsi->device;
> >  	unsigned int Bpp = mipi_dsi_pixel_format_to_bpp(device->format) / 8;
> >  	u16 hbp, hfp, hsa, hblk, vblk;
> > +	u32 basic_ctl = 0;
> >  	size_t bytes;
> >  	u8 *buffer;
> >  
> >  	/* Do all timing calculations up front to allocate buffer space */
> >  
> > -	/*
> > -	 * A sync period is composed of a blanking packet (4 bytes +
> > -	 * payload + 2 bytes) and a sync event packet (4 bytes). Its
> > -	 * minimal size is therefore 10 bytes
> > -	 */
> > +	if (device->mode_flags & MIPI_DSI_MODE_VIDEO_BURST) {
> > +		hsa = 0;
> > +		hbp = 0;
> > +		hfp = 0;
> > +		hblk = mode->hdisplay * Bpp;
> > +		vblk = 0;
> 
> It looks a bit strange to zero these variables here while basic_ctl is
> initialized to zero when declared. I think it would be more consistent
> to have these variables set to zero in the same fashion.

You're right, I've fixed this while applying.

> With that fixed:
> 
> Reviewed-by: Paul Kocialkowski <paul.kocialkowski@xxxxxxxxxxx>

Thanks!
Maxime

-- 
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

Attachment: signature.asc
Description: PGP signature

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel

[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux