From f1f3f98272b9bb1ba87c2ccbc811b038574cec43 Mon Sep 17 00:00:00 2001 From: Matthew Auld Date: Fri, 6 Oct 2017 23:18:32 +0100 Subject: [PATCH] drm/i915: enable platform support for 64K pages For gen9+ enable platform level support for 64K pages. Also enable for mock testing. Signed-off-by: Matthew Auld Cc: Joonas Lahtinen Cc: Chris Wilson Reviewed-by: Chris Wilson Link: https://patchwork.freedesktop.org/patch/msgid/20171006145041.21673-21-matthew.auld@intel.com Signed-off-by: Chris Wilson Link: https://patchwork.freedesktop.org/patch/msgid/20171006221833.32439-20-chris@chris-wilson.co.uk --- drivers/gpu/drm/i915/i915_pci.c | 3 ++- drivers/gpu/drm/i915/selftests/mock_gem_device.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c index 7938006cf03ad..8d349aec19029 100644 --- a/drivers/gpu/drm/i915/i915_pci.c +++ b/drivers/gpu/drm/i915/i915_pci.c @@ -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, \ diff --git a/drivers/gpu/drm/i915/selftests/mock_gem_device.c b/drivers/gpu/drm/i915/selftests/mock_gem_device.c index f46c3a35d61a7..7a9735dac9128 100644 --- a/drivers/gpu/drm/i915/selftests/mock_gem_device.c +++ b/drivers/gpu/drm/i915/selftests/mock_gem_device.c @@ -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); -- 2.39.5