sna: Enable relaxed-fencing for gen2 devices

(Just as dependent upon non-buggy kernels as gen3...)

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2011-07-04 13:44:28 +01:00
parent 33ddaf5429
commit 3e53b0f3a3
1 changed files with 2 additions and 6 deletions

View File

@ -347,12 +347,8 @@ void kgem_init(struct kgem *kgem, int fd, struct pci_device *dev, int gen)
gp.param = I915_PARAM_HAS_RELAXED_FENCING;
gp.value = &i;
if (drmIoctl(kgem->fd, DRM_IOCTL_I915_GETPARAM, &gp) == 0) {
if (gen < 33)
kgem->has_relaxed_fencing = i >= 2;
else
kgem->has_relaxed_fencing = i > 0;
}
if (drmIoctl(kgem->fd, DRM_IOCTL_I915_GETPARAM, &gp) == 0)
kgem->has_relaxed_fencing = i > 0;
}
} else
kgem->has_relaxed_fencing = 1;