From d611a3226cb97e33b5fe7e43234e91d126de9c42 Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Thu, 8 Aug 2013 00:53:17 +0200 Subject: [PATCH] backprots: fix logic in calling intel_enable_gtt() The old patch changed the or condition to an and condition which is wrong. This patch fixes the logic again. Signed-off-by: Hauke Mehrtens Signed-off-by: Luis R. Rodriguez --- .../drivers_gpu_drm_i915_i915_gem.patch | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/patches/collateral-evolutions/drm/07-intel-gtt/drivers_gpu_drm_i915_i915_gem.patch b/patches/collateral-evolutions/drm/07-intel-gtt/drivers_gpu_drm_i915_i915_gem.patch index 486693b490e7..c1e6acc4255e 100644 --- a/patches/collateral-evolutions/drm/07-intel-gtt/drivers_gpu_drm_i915_i915_gem.patch +++ b/patches/collateral-evolutions/drm/07-intel-gtt/drivers_gpu_drm_i915_i915_gem.patch @@ -1,18 +1,13 @@ --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c -@@ -4147,9 +4147,14 @@ i915_gem_init_hw(struct drm_device *dev) +@@ -4147,8 +4147,10 @@ i915_gem_init_hw(struct drm_device *dev) drm_i915_private_t *dev_priv = dev->dev_private; int ret; -- if (INTEL_INFO(dev)->gen < 6 && !intel_enable_gtt()) -+ if (INTEL_INFO(dev)->gen < 6) - return -EIO; - +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,6,0)) -+ if (!intel_enable_gtt()) -+ return -EIO; + if (INTEL_INFO(dev)->gen < 6 && !intel_enable_gtt()) + return -EIO; +#endif -+ + if (IS_HASWELL(dev) && (I915_READ(0x120010) == 1)) I915_WRITE(0x9008, I915_READ(0x9008) | 0xf0000); - -- 2.30.2