ACK: [PATCH 1/1] UBUNTU: SAUCE: Revert "drm/i915: Fix hotplug irq ack on i965/g4x"
Kleber Souza
kleber.souza at canonical.com
Wed Mar 27 16:46:41 UTC 2019
On 3/12/19 6:30 PM, Kai-Heng Feng wrote:
> BugLink: https://bugs.launchpad.net/bugs/1819486
>
> This reverts commit 2f2a7c6570455b1d49161f14ecd1438b3504deab.
>
> Signed-off-by: Kai-Heng Feng <kai.heng.feng at canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza at canonical.com>
> ---
> drivers/gpu/drm/i915/i915_irq.c | 32 ++------------------------------
> 1 file changed, 2 insertions(+), 30 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
> index 38d6d1bfe14e..f6d496c09d3f 100644
> --- a/drivers/gpu/drm/i915/i915_irq.c
> +++ b/drivers/gpu/drm/i915/i915_irq.c
> @@ -1956,38 +1956,10 @@ static void valleyview_pipestat_irq_handler(struct drm_i915_private *dev_priv,
>
> static u32 i9xx_hpd_irq_ack(struct drm_i915_private *dev_priv)
> {
> - u32 hotplug_status = 0, hotplug_status_mask;
> - int i;
> -
> - if (IS_G4X(dev_priv) ||
> - IS_VALLEYVIEW(dev_priv) || IS_CHERRYVIEW(dev_priv))
> - hotplug_status_mask = HOTPLUG_INT_STATUS_G4X |
> - DP_AUX_CHANNEL_MASK_INT_STATUS_G4X;
> - else
> - hotplug_status_mask = HOTPLUG_INT_STATUS_I915;
> + u32 hotplug_status = I915_READ(PORT_HOTPLUG_STAT);
>
> - /*
> - * We absolutely have to clear all the pending interrupt
> - * bits in PORT_HOTPLUG_STAT. Otherwise the ISR port
> - * interrupt bit won't have an edge, and the i965/g4x
> - * edge triggered IIR will not notice that an interrupt
> - * is still pending. We can't use PORT_HOTPLUG_EN to
> - * guarantee the edge as the act of toggling the enable
> - * bits can itself generate a new hotplug interrupt :(
> - */
> - for (i = 0; i < 10; i++) {
> - u32 tmp = I915_READ(PORT_HOTPLUG_STAT) & hotplug_status_mask;
> -
> - if (tmp == 0)
> - return hotplug_status;
> -
> - hotplug_status |= tmp;
> + if (hotplug_status)
> I915_WRITE(PORT_HOTPLUG_STAT, hotplug_status);
> - }
> -
> - WARN_ONCE(1,
> - "PORT_HOTPLUG_STAT did not clear (0x%08x)\n",
> - I915_READ(PORT_HOTPLUG_STAT));
>
> return hotplug_status;
> }
More information about the kernel-team
mailing list