[PATCH 04/13] drm/imx: Make pipe number unsigned

Thierry Reding thierry.reding at gmail.com
Thu Aug 13 02:05:23 PDT 2015


On Wed, Aug 12, 2015 at 05:24:34PM +0200, Daniel Vetter wrote:
> On Wed, Aug 12, 2015 at 05:00:26PM +0200, Thierry Reding wrote:
> > From: Thierry Reding <treding at nvidia.com>
> > 
> > There's no reason whatsoever why this should ever be negative.
> > 
> > Cc: Philipp Zabel <p.zabel at pengutronix.de>
> > Acked-by: Philipp Zabel <p.zabel at pengutronix.de>
> > Signed-off-by: Thierry Reding <treding at nvidia.com>
> 
> Just kill it and replace with drm_crtc_index. Using that for vblank events
> instead of some driver-specific thing is kinda abi.

Would you mind if I did that as a follow-up? That way the changes per
patch stay more concise.

Thierry

> > ---
> >  drivers/gpu/drm/imx/imx-drm-core.c | 4 ++--
> >  drivers/gpu/drm/imx/imx-drm.h      | 2 +-
> >  2 files changed, 3 insertions(+), 3 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/imx/imx-drm-core.c b/drivers/gpu/drm/imx/imx-drm-core.c
> > index 74f505b0dd02..c50cd97b1c4e 100644
> > --- a/drivers/gpu/drm/imx/imx-drm-core.c
> > +++ b/drivers/gpu/drm/imx/imx-drm-core.c
> > @@ -45,14 +45,14 @@ struct imx_drm_device {
> >  
> >  struct imx_drm_crtc {
> >  	struct drm_crtc				*crtc;
> > -	int					pipe;
> > +	unsigned int				pipe;
> >  	struct imx_drm_crtc_helper_funcs	imx_drm_helper_funcs;
> >  };
> >  
> >  static int legacyfb_depth = 16;
> >  module_param(legacyfb_depth, int, 0444);
> >  
> > -int imx_drm_crtc_id(struct imx_drm_crtc *crtc)
> > +unsigned int imx_drm_crtc_id(struct imx_drm_crtc *crtc)
> >  {
> >  	return crtc->pipe;
> >  }
> > diff --git a/drivers/gpu/drm/imx/imx-drm.h b/drivers/gpu/drm/imx/imx-drm.h
> > index 28e776d8d9d2..eebf0e2fefd0 100644
> > --- a/drivers/gpu/drm/imx/imx-drm.h
> > +++ b/drivers/gpu/drm/imx/imx-drm.h
> > @@ -12,7 +12,7 @@ struct drm_framebuffer;
> >  struct imx_drm_crtc;
> >  struct platform_device;
> >  
> > -int imx_drm_crtc_id(struct imx_drm_crtc *crtc);
> > +unsigned int imx_drm_crtc_id(struct imx_drm_crtc *crtc);
> >  
> >  struct imx_drm_crtc_helper_funcs {
> >  	int (*enable_vblank)(struct drm_crtc *crtc);
> > -- 
> > 2.4.5
> > 
> 
> -- 
> Daniel Vetter
> Software Engineer, Intel Corporation
> http://blog.ffwll.ch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/dri-devel/attachments/20150813/3b84010d/attachment.sig>


More information about the dri-devel mailing list