drm/i915: enable platform support for 64K pages
authorMatthew Auld <matthew.auld@intel.com>
Fri, 6 Oct 2017 22:18:32 +0000 (23:18 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Sat, 7 Oct 2017 09:12:04 +0000 (10:12 +0100)
For gen9+ enable platform level support for 64K pages. Also enable for
mock testing.

Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20171006145041.21673-21-matthew.auld@intel.com
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20171006221833.32439-20-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_pci.c
drivers/gpu/drm/i915/selftests/mock_gem_device.c

index 7938006cf03ade85aa62b2b648e134d0e3bd7df7..8d349aec1902936640b65e564fe773690e748d54 100644 (file)
@@ -436,7 +436,8 @@ static const struct intel_device_info intel_cherryview_info __initconst = {
 };
 
 #define GEN9_DEFAULT_PAGE_SIZES \
-       .page_sizes = I915_GTT_PAGE_SIZE_4K
+       .page_sizes = I915_GTT_PAGE_SIZE_4K | \
+                     I915_GTT_PAGE_SIZE_64K
 
 #define GEN9_FEATURES \
        GEN8_FEATURES, \
index f46c3a35d61a7e1b9599075a0327119d1c9b644a..7a9735dac91284bf993dd4fd254fd22ce884966f 100644 (file)
@@ -175,7 +175,8 @@ struct drm_i915_private *mock_gem_device(void)
        mkwrite_device_info(i915)->gen = -1;
 
        mkwrite_device_info(i915)->page_sizes =
-               I915_GTT_PAGE_SIZE_4K;
+               I915_GTT_PAGE_SIZE_4K |
+               I915_GTT_PAGE_SIZE_64K;
 
        spin_lock_init(&i915->mm.object_stat_lock);
        mock_uncore_init(i915);