stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: torvalds@linux-foundation.org, akpm@linux-foundation.org,
	alan@lxorguk.ukuu.org.uk,
	Markus Heinz <markus.heinz@uni-dortmund.de>,
	Chris Wilson <chris@chris-wilson.co.uk>,
	Rodrigo Vivi <rodrigo.vivi@gmail.com>,
	Daniel Vetter <daniel.vetter@ffwll.ch>
Subject: [ 21/42] drm/i915: quirk away broken OpRegion VBT
Date: Wed, 11 Apr 2012 16:13:28 -0700	[thread overview]
Message-ID: <20120411231310.915461092@linuxfoundation.org> (raw)
In-Reply-To: <20120411231443.GA808@kroah.com>

3.0-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Daniel Vetter <daniel.vetter@ffwll.ch>

commit 25e341cfc33d94435472983825163e97fe370a6c upstream.

Somehow the BIOS manages to screw things up when copying the VBT
around, because the one we scrap from the VBIOS rom actually works.

Tested-by: Markus Heinz <markus.heinz@uni-dortmund.de>
Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=28812
Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
 drivers/gpu/drm/i915/intel_bios.c |   23 ++++++++++++++++++++++-
 1 file changed, 22 insertions(+), 1 deletion(-)

--- a/drivers/gpu/drm/i915/intel_bios.c
+++ b/drivers/gpu/drm/i915/intel_bios.c
@@ -24,6 +24,7 @@
  *    Eric Anholt <eric@anholt.net>
  *
  */
+#include <linux/dmi.h>
 #include <drm/drm_dp_helper.h>
 #include "drmP.h"
 #include "drm.h"
@@ -592,6 +593,26 @@ init_vbt_defaults(struct drm_i915_privat
 	dev_priv->edp.bpp = 18;
 }
 
+static int __init intel_no_opregion_vbt_callback(const struct dmi_system_id *id)
+{
+	DRM_DEBUG_KMS("Falling back to manually reading VBT from "
+		      "VBIOS ROM for %s\n",
+		      id->ident);
+	return 1;
+}
+
+static const struct dmi_system_id intel_no_opregion_vbt[] = {
+	{
+		.callback = intel_no_opregion_vbt_callback,
+		.ident = "ThinkCentre A57",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "97027RG"),
+		},
+	},
+	{ }
+};
+
 /**
  * intel_parse_bios - find VBT and initialize settings from the BIOS
  * @dev: DRM device
@@ -612,7 +633,7 @@ intel_parse_bios(struct drm_device *dev)
 	init_vbt_defaults(dev_priv);
 
 	/* XXX Should this validation be moved to intel_opregion.c? */
-	if (dev_priv->opregion.vbt) {
+	if (!dmi_check_system(intel_no_opregion_vbt) && dev_priv->opregion.vbt) {
 		struct vbt_header *vbt = dev_priv->opregion.vbt;
 		if (memcmp(vbt->signature, "$VBT", 4) == 0) {
 			DRM_DEBUG_DRIVER("Using VBT from OpRegion: %20s\n",



  parent reply	other threads:[~2012-04-11 23:13 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-11 23:14 [ 00/42] 3.0.28-stable review Greg KH
2012-04-11 23:13 ` [ 01/42] x86 bpf_jit: fix a bug in emitting the 16-bit immediate operand of AND Greg KH
2012-04-11 23:13 ` [ 02/42] rose_dev: fix memcpy-bug in rose_set_mac_address Greg KH
2012-04-11 23:13 ` [ 03/42] net: usb: cdc_eem: fix mtu Greg KH
2012-04-11 23:13 ` [ 04/42] mtd: sst25l: initialize writebufsize Greg KH
2012-04-11 23:13 ` [ 05/42] mtd: block2mtd: " Greg KH
2012-04-11 23:13 ` [ 06/42] mtd: lart: " Greg KH
2012-04-11 23:13 ` [ 07/42] mtd: m25p80: set writebufsize Greg KH
2012-04-11 23:13 ` [ 08/42] ACPI: Do cpufreq clamping for throttling per package v2 Greg KH
2012-04-11 23:13 ` [ 09/42] PNPACPI: Fix device ref leaking in acpi_pnp_match Greg KH
2012-04-11 23:13 ` [ 10/42] ACPICA: Fix regression in FADT revision checks Greg KH
2012-04-11 23:13 ` [ 11/42] modpost: fix ALL_INIT_DATA_SECTIONS Greg KH
2012-04-11 23:13 ` [ 12/42] genirq: Adjust irq thread affinity on IRQ_SET_MASK_OK_NOCOPY return value Greg KH
2012-04-11 23:13 ` [ 13/42] tracing: Fix ftrace stack trace entries Greg KH
2012-04-11 23:13 ` [ 14/42] m68k/mac: Add missing platform check before registering platform devices Greg KH
2012-04-11 23:13 ` [ 15/42] mac80211: fix possible tid_rx->reorder_timer use after free Greg KH
2012-04-11 23:13 ` [ 16/42] drm: Validate requested virtual size against allocated fb size Greg KH
2012-04-11 23:13 ` [ 17/42] drm/radeon/kms: fix fans after resume Greg KH
2012-04-11 23:13 ` [ 18/42] drm/i915: no-lvds quirk on MSI DC500 Greg KH
2012-04-11 23:13 ` [ 19/42] drm/i915: Sanitize BIOS debugging bits from PIPECONF Greg KH
2012-04-11 23:13 ` [ 20/42] drm/i915: Add lock on drm_helper_resume_force_mode Greg KH
2012-04-11 23:13 ` Greg KH [this message]
2012-04-11 23:13 ` [ 22/42] kgdb,debug_core: pass the breakpoint struct instead of address and memory Greg KH
2012-04-11 23:13 ` [ 23/42] kgdbts: Fix kernel oops with CONFIG_DEBUG_RODATA Greg KH
2012-04-11 23:13 ` [ 24/42] kgdbts: (1 of 2) fix single step awareness to work correctly with SMP Greg KH
2012-04-11 23:13 ` [ 25/42] kgdbts: (2 " Greg KH
2012-04-11 23:13 ` [ 26/42] x86,kgdb: Fix DEBUG_RODATA limitation using text_poke() Greg KH
2012-04-11 23:13 ` [ 27/42] mmc: atmel-mci: correct data timeout computation Greg KH
2012-04-11 23:13 ` [ 28/42] sysctl: fix write access to dmesg_restrict/kptr_restrict Greg KH
2012-04-11 23:13 ` [ 29/42] modpost: Fix modposts license checking V3 Greg KH
2012-04-11 23:13 ` [ 30/42] modpost: Fix modpost license checking of vmlinux.o Greg KH
2012-04-11 23:13 ` [ 31/42] x86/PCI: use host bridge _CRS info on MSI MS-7253 Greg KH
2012-04-11 23:13 ` [ 32/42] x86/PCI: do not tie MSI MS-7253 use_crs quirk to BIOS version Greg KH
2012-04-11 23:13 ` [ 33/42] Revert "x86/ioapic: Add register level checks to detect bogus io-apic entries" Greg KH
2012-04-11 23:13 ` [ 34/42] acer-wmi: No wifi rfkill on Sony machines Greg KH
2012-04-11 23:13 ` [ 35/42] sched/x86: Fix overflow in cyc2ns_offset Greg KH
2012-04-11 23:13 ` [ 36/42] mfd: Clear twl6030 IRQ status register only once Greg KH
2012-04-11 23:13 ` [ 37/42] USB: Add Motorola Rokr E6 Id to the USBNet driver "zaurus" Greg KH
2012-04-11 23:13 ` [ 38/42] ASoC: ak4642: fixup: mute needs +1 step Greg KH
2012-04-11 23:13 ` [ 39/42] cred: copy_process() should clear child->replacement_session_keyring Greg KH
2012-04-11 23:13 ` [ 40/42] iommu/amd: Make sure IOMMU interrupts are re-enabled on resume Greg KH
2012-04-11 23:13 ` [ 41/42] TOMOYO: Fix mount flags checking order Greg KH
2012-04-11 23:13 ` [ 42/42] Bluetooth: Fix l2cap conn failures for ssp devices Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120411231310.915461092@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=akpm@linux-foundation.org \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=chris@chris-wilson.co.uk \
    --cc=daniel.vetter@ffwll.ch \
    --cc=linux-kernel@vger.kernel.org \
    --cc=markus.heinz@uni-dortmund.de \
    --cc=rodrigo.vivi@gmail.com \
    --cc=stable@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).