intel: check for LLC support when reading maps
authorEugeni Dodonov <eugeni.dodonov@intel.com>
Wed, 1 Feb 2012 20:24:23 +0000 (18:24 -0200)
committerEugeni Dodonov <eugeni.dodonov@intel.com>
Sat, 4 Feb 2012 20:21:22 +0000 (18:21 -0200)
This checks for advertised LLC support by the GPU instead of relying on
the GPU generation for detection.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
src/mesa/drivers/dri/intel/intel_mipmap_tree.c

index eae79c10592c17642114ba62bbc1326204f7448a..5290da4d6f337924ea4b46ce2e8f86b1a5962bb6 100644 (file)
@@ -1052,7 +1052,7 @@ intel_miptree_map(struct intel_context *intel,
       intel_miptree_map_s8(intel, mt, map, level, slice);
    } else if (mt->stencil_mt) {
       intel_miptree_map_depthstencil(intel, mt, map, level, slice);
-   } else if (intel->gen >= 6 &&
+   } else if (intel->has_llc &&
              !(mode & GL_MAP_WRITE_BIT) &&
              !mt->compressed &&
              mt->region->tiling == I915_TILING_X) {