[Intel-gfx] [PATCH 13/14] drm/i915: Use vlv display irq setup code for chv

Daniel Vetter daniel at ffwll.ch
Mon Nov 3 17:37:13 CET 2014


On Thu, Oct 30, 2014 at 06:41:11PM -0200, Paulo Zanoni wrote:
> 2014-10-30 15:43 GMT-02:00  <ville.syrjala at linux.intel.com>:
> >
> >         gen8_gt_irq_postinstall(dev_priv);
> >
> > @@ -3620,7 +3594,6 @@ static void valleyview_irq_uninstall(struct drm_device *dev)
> >  static void cherryview_irq_uninstall(struct drm_device *dev)
> >  {
> >         struct drm_i915_private *dev_priv = dev->dev_private;
> > -       int pipe;
> >
> >         if (!dev_priv)
> >                 return;
> > @@ -3632,13 +3605,7 @@ static void cherryview_irq_uninstall(struct drm_device *dev)
> >
> >         GEN5_IRQ_RESET(GEN8_PCU_);
> >
> > -       I915_WRITE(PORT_HOTPLUG_EN, 0);
> > -       I915_WRITE(PORT_HOTPLUG_STAT, I915_READ(PORT_HOTPLUG_STAT));
> > -
> > -       for_each_pipe(dev_priv, pipe)
> > -               I915_WRITE(PIPESTAT(pipe), 0xffff);
> > -
> > -       GEN5_IRQ_RESET(VLV_);
> > +       vlv_display_irq_uninstall(dev_priv);
> 
> The perfect match for the code you removed seems to be
> vlv_display_irq_reset(). Why use vlv_display_irq_uninstall() instead?

Yeah, if we use _reset we don't have the confusion with shared _uninstall
hooks and can just forgoe that other patch.

Also the general naming scheme is to have split-out functions called
_irq_reset and use them both in _preinstall and _uninstall.
-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