From: Greg Kroah-Hartman Date: Fri, 25 May 2012 05:17:06 +0000 (+0900) Subject: 3.0-stable patches X-Git-Tag: v3.0.33~19 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6e5ebb7ea96b06016f69232ab6dcdc2f5a3e0c5b;p=thirdparty%2Fkernel%2Fstable-queue.git 3.0-stable patches added patches: drm-i915-avoid-a-double-read-of-pch_iir-during-interrupt-handling.patch --- diff --git a/queue-3.0/drm-i915-avoid-a-double-read-of-pch_iir-during-interrupt-handling.patch b/queue-3.0/drm-i915-avoid-a-double-read-of-pch_iir-during-interrupt-handling.patch new file mode 100644 index 00000000000..897674cf941 --- /dev/null +++ b/queue-3.0/drm-i915-avoid-a-double-read-of-pch_iir-during-interrupt-handling.patch @@ -0,0 +1,60 @@ +From 9adab8b5a7fde248504f484e197589f3e3c922e2 Mon Sep 17 00:00:00 2001 +From: Chris Wilson +Date: Wed, 9 May 2012 21:45:43 +0100 +Subject: drm/i915: Avoid a double-read of PCH_IIR during interrupt handling + +From: Chris Wilson + +commit 9adab8b5a7fde248504f484e197589f3e3c922e2 upstream. + +Currently the code re-reads PCH_IIR during the hotplug interrupt +processing. Not only is this a wasted read, but introduces a potential +for handling a spurious interrupt as we then may not clear all the +interrupts processed (since the re-read IIR may contains more interrupts +asserted than we clear using the result of the original read). + +Signed-off-by: Chris Wilson +Cc: Jesse Barnes +Signed-off-by: Daniel Vetter +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/gpu/drm/i915/i915_irq.c | 9 +++------ + 1 file changed, 3 insertions(+), 6 deletions(-) + +--- a/drivers/gpu/drm/i915/i915_irq.c ++++ b/drivers/gpu/drm/i915/i915_irq.c +@@ -422,14 +422,11 @@ static void gen6_pm_rps_work(struct work + mutex_unlock(&dev_priv->dev->struct_mutex); + } + +-static void pch_irq_handler(struct drm_device *dev) ++static void pch_irq_handler(struct drm_device *dev, u32 pch_iir) + { + drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; +- u32 pch_iir; + int pipe; + +- pch_iir = I915_READ(SDEIIR); +- + if (pch_iir & SDE_AUDIO_POWER_MASK) + DRM_DEBUG_DRIVER("PCH audio power change on port %d\n", + (pch_iir & SDE_AUDIO_POWER_MASK) >> +@@ -527,7 +524,7 @@ static irqreturn_t ivybridge_irq_handler + if (de_iir & DE_PCH_EVENT_IVB) { + if (pch_iir & SDE_HOTPLUG_MASK_CPT) + queue_work(dev_priv->wq, &dev_priv->hotplug_work); +- pch_irq_handler(dev); ++ pch_irq_handler(dev, pch_iir); + } + + if (pm_iir & GEN6_PM_DEFERRED_EVENTS) { +@@ -626,7 +623,7 @@ static irqreturn_t ironlake_irq_handler( + if (de_iir & DE_PCH_EVENT) { + if (pch_iir & hotplug_mask) + queue_work(dev_priv->wq, &dev_priv->hotplug_work); +- pch_irq_handler(dev); ++ pch_irq_handler(dev, pch_iir); + } + + if (de_iir & DE_PCU_EVENT) { diff --git a/queue-3.0/series b/queue-3.0/series index 0c2567c2363..6cd6afb137d 100644 --- a/queue-3.0/series +++ b/queue-3.0/series @@ -44,3 +44,4 @@ usb-xhci-handle-comp_tx_err-for-isoc-tds.patch xhci-reset-reserved-command-ring-trbs-on-cleanup.patch xhci-add-new-short-tx-quirk-for-fresco-logic-host.patch usbcore-enable-usb2-lpm-if-port-suspend-fails.patch +drm-i915-avoid-a-double-read-of-pch_iir-during-interrupt-handling.patch