summaryrefslogtreecommitdiff
path: root/src/sna/sna_driver.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2012-07-29 22:51:26 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2012-07-29 22:51:26 +0100
commit0fd680ff52f7ce0a101c617dfb8997c4e228e3ad (patch)
treed2016fc252f773e44c78f6e7cc21a71706e4cf68 /src/sna/sna_driver.c
parent3d45f0affe263985f440e144203ed7cbb3803696 (diff)
Don't disable acceleration on 830/845g by default
Run the risk of a GPU hang (it shouldn't endanger the entire machine normally) and let the user elect to disable it through Option "NoAccel" "true" Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_driver.c')
-rw-r--r--src/sna/sna_driver.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/sna/sna_driver.c b/src/sna/sna_driver.c
index 3f2ff2ed..bd31996b 100644
--- a/src/sna/sna_driver.c
+++ b/src/sna/sna_driver.c
@@ -439,7 +439,14 @@ static Bool sna_pre_init(ScrnInfoPtr scrn, int flags)
return FALSE;
sna->info = intel_detect_chipset(scrn, sna->pEnt, sna->PciInfo);
+
kgem_init(&sna->kgem, fd, sna->PciInfo, sna->info->gen);
+ if (xf86ReturnOptValBool(sna->Options, OPTION_ACCEL_DISABLE, FALSE)) {
+ xf86DrvMsg(sna->scrn->scrnIndex, X_CONFIG,
+ "Disabling hardware acceleration.\n");
+ sna->kgem.wedged = true;
+ }
+
if (!xf86ReturnOptValBool(sna->Options,
OPTION_RELAXED_FENCING,
sna->kgem.has_relaxed_fencing)) {