On Fri, 2020-11-06 at 14:55 -0800, Lucas De Marchi wrote: > Use the convention of new platforms first. No need to special case > HAS_GMCH() since that stopped being true at the lattest on gen8 (for > cherryview). > Reviewed-by: José Roberto de Souza <jose.souza@xxxxxxxxx> > Signed-off-by: Lucas De Marchi <lucas.demarchi@xxxxxxxxx> > --- > drivers/gpu/drm/i915/i915_irq.c | 27 ++++++++++++--------------- > 1 file changed, 12 insertions(+), 15 deletions(-) > > diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c > index e0eb32bd9607..2ab4edf7f25c 100644 > --- a/drivers/gpu/drm/i915/i915_irq.c > +++ b/drivers/gpu/drm/i915/i915_irq.c > @@ -4237,21 +4237,18 @@ void intel_irq_init(struct drm_i915_private *dev_priv) > */ > dev_priv->hotplug.hpd_short_storm_enabled = !HAS_DP_MST(dev_priv); > > > > > - if (HAS_GMCH(dev_priv)) { > - if (I915_HAS_HOTPLUG(dev_priv)) > - dev_priv->display.hpd_irq_setup = i915_hpd_irq_setup; > - } else { > - if (HAS_PCH_DG1(dev_priv)) > - dev_priv->display.hpd_irq_setup = dg1_hpd_irq_setup; > - else if (INTEL_GEN(dev_priv) >= 11) > - dev_priv->display.hpd_irq_setup = gen11_hpd_irq_setup; > - else if (IS_GEN9_LP(dev_priv)) > - dev_priv->display.hpd_irq_setup = bxt_hpd_irq_setup; > - else if (INTEL_PCH_TYPE(dev_priv) >= PCH_SPT) > - dev_priv->display.hpd_irq_setup = spt_hpd_irq_setup; > - else > - dev_priv->display.hpd_irq_setup = ilk_hpd_irq_setup; > - } > + if (HAS_PCH_DG1(dev_priv)) > + dev_priv->display.hpd_irq_setup = dg1_hpd_irq_setup; > + else if (INTEL_GEN(dev_priv) >= 11) > + dev_priv->display.hpd_irq_setup = gen11_hpd_irq_setup; > + else if (IS_GEN9_LP(dev_priv)) > + dev_priv->display.hpd_irq_setup = bxt_hpd_irq_setup; > + else if (INTEL_PCH_TYPE(dev_priv) >= PCH_SPT) > + dev_priv->display.hpd_irq_setup = spt_hpd_irq_setup; > + else if (HAS_GMCH(dev_priv) && I915_HAS_HOTPLUG(dev_priv)) > + dev_priv->display.hpd_irq_setup = i915_hpd_irq_setup; > + else > + dev_priv->display.hpd_irq_setup = ilk_hpd_irq_setup; > } > > > > > /** _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx