[Intel-gfx] [PATCH] drm/i915: Use dev_priv as first argument of for_each_pipe()

Daniel Vetter daniel at ffwll.ch
Tue Aug 26 09:40:29 CEST 2014


On Mon, Aug 18, 2014 at 02:13:06PM +0100, Chris Wilson wrote:
> On Mon, Aug 18, 2014 at 02:07:40PM +0100, Damien Lespiau wrote:
> > On Mon, Aug 18, 2014 at 01:58:06PM +0100, Chris Wilson wrote:
> > > On Mon, Aug 18, 2014 at 01:49:10PM +0100, Damien Lespiau wrote:
> > > > Chris has decided that enough is enough. It's time to fixup dev Vs
> > > > dev_priv. This is a modest contribution to the crusade.
> > > > 
> > > > v2: Still use INTEL_INFO(), for the (mythical!) case we want to hardcode
> > > >     the info struct with defines (Chris)
> > > >     Rename the macro argument from 'dev' to 'dev_priv' (Jani)
> > > > 
> > > > v3: Use names unlikely to be used as macro arguments (Chris)
> > > 
> > > I can be annoying! These macros typically take the iter as the first
> > > argument...
> > 
> > How typical is your typical?
> 
> list_for_each and everything derived from them that paid attention...
>  
> > #define for_each_pipe(__dev_priv, __p)
> > #define for_each_crtc(dev, crtc)
> > #define for_each_intel_crtc(dev, intel_crtc)
> > #define for_each_intel_encoder(dev, intel_encoder) 
> > #define for_each_encoder_on_crtc(dev, __crtc, intel_encoder)
> > #define for_each_connector_on_encoder(dev, __encoder, intel_connector)
> > 
> > Sounds like a lot of churn for no good reason this time.
> 
> Or that I forgot to tell you about this detail last time.

I think a lot of those are on me ;-) Patch merged to dinq, thanks.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch



More information about the Intel-gfx mailing list