[2/3] UBUNTU: SAUCE: Nouveau: Disable acceleration on MacBook Pros

Submitted by Andy Whitcroft on April 9, 2010, 3:22 p.m.

Details

Message ID 1270826530-23810-2-git-send-email-apw@canonical.com
State Accepted
Delegated to: Andy Whitcroft
Headers show

Commit Message

Andy Whitcroft April 9, 2010, 3:22 p.m.
From: Christopher James Halse Rogers <raof@ubuntu.com>

Upstream obviously wants to fix acceleration rather than disable it.
For Lucid however we need these cards to boot more than we need them to
be fast.

With acceleration enabled these cards hang during boot.

BugLink: http://bugs.launchpad.net/bugs/546393

Signed-off-by: Christopher James Halse Rogers <raof@ubuntu.com>
Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
 drivers/gpu/drm/nouveau/nouveau_state.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/nouveau/nouveau_state.c b/drivers/gpu/drm/nouveau/nouveau_state.c
index 5a391fb..462432c 100644
--- a/drivers/gpu/drm/nouveau/nouveau_state.c
+++ b/drivers/gpu/drm/nouveau/nouveau_state.c
@@ -605,6 +605,15 @@  static void nouveau_apply_noaccel_quirks (struct drm_device *dev)
 	if (nouveau_noaccel == -1) {
 		/* If not specified, noaccel should default off */
 		nouveau_noaccel = 0;
+
+		/* MacBook Pro laptops with 9600GT cards hang with acceleration */
+		/* See https://bugs.launchpad.net/bugs/546393 */
+		if ((dev->pdev->device == 0x0647) &&
+		    (dev->pdev->subsystem_vendor == 0x106b)) {
+			nouveau_noaccel = 1;
+			NV_INFO(dev, "Detected MacBook Pro 9600GT chip. "
+				 "Disabling acceleration\n");
+		}
 	}
 }