From: Greg Kroah-Hartman Date: Tue, 18 Feb 2014 22:01:37 +0000 (-0800) Subject: 3.4-stable patches X-Git-Tag: v3.4.81~11 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=40a245fd322183be0fe2f8538d97e1476ec71f06;p=thirdparty%2Fkernel%2Fstable-queue.git 3.4-stable patches added patches: drm-i915-kick-any-firmware-framebuffers-before-claiming-the-gtt.patch --- diff --git a/queue-3.4/alsa-hda-realtek-avoid-invalid-coefs-for-alc271x.patch b/queue-3.4/alsa-hda-realtek-avoid-invalid-coefs-for-alc271x.patch deleted file mode 100644 index c1d2d5c7bce..00000000000 --- a/queue-3.4/alsa-hda-realtek-avoid-invalid-coefs-for-alc271x.patch +++ /dev/null @@ -1,38 +0,0 @@ -From d3c56568f43807135f2c2a09582a69f809f0d8b7 Mon Sep 17 00:00:00 2001 -From: Takashi Iwai -Date: Mon, 3 Feb 2014 09:56:13 +0100 -Subject: ALSA: hda/realtek - Avoid invalid COEFs for ALC271X - -From: Takashi Iwai - -commit d3c56568f43807135f2c2a09582a69f809f0d8b7 upstream. - -We've seen often problems after suspend/resume on Acer Aspire One -AO725 with ALC271X codec as reported in kernel bugzilla, and it turned -out that some COEFs doesn't work and triggers the codec communication -stall. - -Since these magic COEF setups are specific to ALC269VB for some PLL -configurations, the machine works even without these manual -adjustment. So, let's simply avoid applying them for ALC271X. - -Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=52181 -Signed-off-by: Takashi Iwai -Signed-off-by: Greg Kroah-Hartman - ---- - sound/pci/hda/patch_realtek.c | 3 +++ - 1 file changed, 3 insertions(+) - ---- a/sound/pci/hda/patch_realtek.c -+++ b/sound/pci/hda/patch_realtek.c -@@ -6260,6 +6260,9 @@ static void alc269_fill_coef(struct hda_ - - if (spec->codec_variant != ALC269_TYPE_ALC269VB) - return; -+ /* ALC271X doesn't seem to support these COEFs (bko#52181) */ -+ if (!strcmp(codec->chip_name, "ALC271X")) -+ return; - - if ((alc_get_coef0(codec) & 0x00ff) < 0x015) { - alc_write_coef_idx(codec, 0xf, 0x960b); diff --git a/queue-3.4/drm-i915-kick-any-firmware-framebuffers-before-claiming-the-gtt.patch b/queue-3.4/drm-i915-kick-any-firmware-framebuffers-before-claiming-the-gtt.patch new file mode 100644 index 00000000000..2bf25695da8 --- /dev/null +++ b/queue-3.4/drm-i915-kick-any-firmware-framebuffers-before-claiming-the-gtt.patch @@ -0,0 +1,117 @@ +From 9f846a16d213523fbe6daea17e20df6b8ac5a1e5 Mon Sep 17 00:00:00 2001 +From: Daniel Vetter +Date: Sun, 1 Jul 2012 17:09:42 +0200 +Subject: drm/i915: kick any firmware framebuffers before claiming the gtt + +From: Daniel Vetter + +commit 9f846a16d213523fbe6daea17e20df6b8ac5a1e5 upstream. + +Especially vesafb likes to map everything as uc- (yikes), and if that +mapping hangs around still while we try to map the gtt as wc the +kernel will downgrade our request to uc-, resulting in abyssal +performance. + +Unfortunately we can't do this as early as readon does (i.e. as the +first thing we do when initializing the hw) because our fb/mmio space +region moves around on a per-gen basis. So I've had to move it below +the gtt initialization, but that seems to work, too. The important +thing is that we do this before we set up the gtt wc mapping. + +Now an altogether different question is why people compile their +kernels with vesafb enabled, but I guess making things just work isn't +bad per se ... + +v2: +- s/radeondrmfb/inteldrmfb/ +- fix up error handling + +v3: Kill #ifdef X86, this is Intel after all. Noticed by Ben Widawsky. + +v4: Jani Nikula complained about the pointless bool primary +initialization. + +v5: Don't oops if we can't allocate, noticed by Chris Wilson. + +v6: Resolve conflicts with agp rework and fixup whitespace. + +This is commit e188719a2891f01b3100d in drm-next. + +Backport to 3.5 -fixes queue requested by Dave Airlie - due to grub +using vesa on fedora their initrd seems to load vesafb before loading +the real kms driver. So tons more people actually experience a +dead-slow gpu. Hence also the Cc: stable. + +Reported-and-tested-by: "Kilarski, Bernard R" +Reviewed-by: Chris Wilson +Signed-off-by: Daniel Vetter +Signed-off-by: Dave Airlie +[lizf: Backported to 3.4: adjust context] +Signed-off-by: Li Zefan +Signed-off-by: Greg Kroah-Hartman + + +--- + drivers/gpu/drm/i915/i915_dma.c | 37 ++++++++++++++++++++++++++++++------- + 1 file changed, 30 insertions(+), 7 deletions(-) + +--- a/drivers/gpu/drm/i915/i915_dma.c ++++ b/drivers/gpu/drm/i915/i915_dma.c +@@ -1934,6 +1934,27 @@ ips_ping_for_i915_load(void) + } + } + ++static void i915_kick_out_firmware_fb(struct drm_i915_private *dev_priv) ++{ ++ struct apertures_struct *ap; ++ struct pci_dev *pdev = dev_priv->dev->pdev; ++ bool primary; ++ ++ ap = alloc_apertures(1); ++ if (!ap) ++ return; ++ ++ ap->ranges[0].base = dev_priv->dev->agp->base; ++ ap->ranges[0].size = ++ dev_priv->mm.gtt->gtt_mappable_entries << PAGE_SHIFT; ++ primary = ++ pdev->resource[PCI_ROM_RESOURCE].flags & IORESOURCE_ROM_SHADOW; ++ ++ remove_conflicting_framebuffers(ap, "inteldrmfb", primary); ++ ++ kfree(ap); ++} ++ + /** + * i915_driver_load - setup chip and create an initial config + * @dev: DRM device +@@ -1971,6 +1992,15 @@ int i915_driver_load(struct drm_device * + goto free_priv; + } + ++ dev_priv->mm.gtt = intel_gtt_get(); ++ if (!dev_priv->mm.gtt) { ++ DRM_ERROR("Failed to initialize GTT\n"); ++ ret = -ENODEV; ++ goto put_bridge; ++ } ++ ++ i915_kick_out_firmware_fb(dev_priv); ++ + pci_set_master(dev->pdev); + + /* overlay on gen2 is broken and can't address above 1G */ +@@ -1996,13 +2026,6 @@ int i915_driver_load(struct drm_device * + goto put_bridge; + } + +- dev_priv->mm.gtt = intel_gtt_get(); +- if (!dev_priv->mm.gtt) { +- DRM_ERROR("Failed to initialize GTT\n"); +- ret = -ENODEV; +- goto out_rmmap; +- } +- + agp_size = dev_priv->mm.gtt->gtt_mappable_entries << PAGE_SHIFT; + + dev_priv->mm.gtt_mapping = diff --git a/queue-3.4/series b/queue-3.4/series index 84b3b6c2827..aa5c86d575b 100644 --- a/queue-3.4/series +++ b/queue-3.4/series @@ -1,7 +1,7 @@ selinux-fix-kernel-bug-on-empty-security-contexts.patch -alsa-hda-realtek-avoid-invalid-coefs-for-alc271x.patch mm-__set_page_dirty_nobuffers-uses-spin_lock_irqsave-instead-of-spin_lock_irq.patch mm-__set_page_dirty-uses-spin_lock_irqsave-instead-of-spin_lock_irq.patch x86-hweight-fix-bug-when-booting-with-config_gcov_profile_all-y.patch printk-fix-scheduling-while-atomic-problem-in-console_cpu_notify.patch ext4-protect-group-inode-free-counting-with-group-lock.patch +drm-i915-kick-any-firmware-framebuffers-before-claiming-the-gtt.patch