diff options
author | Matthew Auld <matthew.auld@intel.com> | 2022-02-25 15:54:56 +0100 |
---|---|---|
committer | Matthew Auld <matthew.auld@intel.com> | 2022-02-28 09:47:27 +0100 |
commit | 235582ca96214b50fa03ea77a5e85e59d94cf358 (patch) | |
tree | 088e7fa89caf84cb4e1a5f02b37d6fc3e1d6924f /drivers/gpu/drm/i915/selftests/mock_region.c | |
parent | drm/i915: apply PM_EARLY for non-GTT mappable objects (diff) | |
download | linux-235582ca96214b50fa03ea77a5e85e59d94cf358.tar.xz linux-235582ca96214b50fa03ea77a5e85e59d94cf358.zip |
drm/i915: add io_size plumbing
With small LMEM-BAR we need to be able to differentiate between the
total size of LMEM, and how much of it is CPU mappable. The end goal is
to be able to utilize the entire range, even if part of is it not CPU
accessible.
v2: also update intelfb_create
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Acked-by: Nirmoy Das <nirmoy.das@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220225145502.331818-1-matthew.auld@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/selftests/mock_region.c')
-rw-r--r-- | drivers/gpu/drm/i915/selftests/mock_region.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/selftests/mock_region.c b/drivers/gpu/drm/i915/selftests/mock_region.c index 19bff8afcaaa..467eeae6d5f0 100644 --- a/drivers/gpu/drm/i915/selftests/mock_region.c +++ b/drivers/gpu/drm/i915/selftests/mock_region.c @@ -107,7 +107,8 @@ mock_region_create(struct drm_i915_private *i915, resource_size_t start, resource_size_t size, resource_size_t min_page_size, - resource_size_t io_start) + resource_size_t io_start, + resource_size_t io_size) { int instance = ida_alloc_max(&i915->selftest.mock_region_instances, TTM_NUM_MEM_TYPES - TTM_PL_PRIV - 1, @@ -117,6 +118,7 @@ mock_region_create(struct drm_i915_private *i915, return ERR_PTR(instance); return intel_memory_region_create(i915, start, size, min_page_size, - io_start, INTEL_MEMORY_MOCK, instance, + io_start, io_size, + INTEL_MEMORY_MOCK, instance, &mock_region_ops); } |