Revert "drm/i915/lmem: Limit block size to 4G"
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 2 Dec 2020 17:34:44 +0000 (17:34 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 2 Dec 2020 20:59:29 +0000 (20:59 +0000)
commit7d1a31e128d3cb939cd70c95f898c13f85155571
tree5cdffe81cc1fdb8d5a58437c9fa99061ef048fab
parenta2843b3bd17e5a1c6b270709dc5bb0091eba1074
Revert "drm/i915/lmem: Limit block size to 4G"

Mixing I915_ALLOC_CONTIGUOUS and I915_ALLOC_MAX_SEGMENT_SIZE fared
badly. The two directives conflict, with the contiguous request setting
the min_order to the full size of the object, and the max-segment-size
setting the max_order to the limit of the DMA mapper. This results in a
situation where max_order < min_order, causing our sanity checks to
fail.

Instead of limiting the buddy block size, in the previous patch we split
the oversized buddy into multiple scatterlist elements.

Fixes: d2cf0125d4a1 ("drm/i915/lmem: Limit block size to 4G")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201202173444.14903-2-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gem/i915_gem_region.c
drivers/gpu/drm/i915/intel_memory_region.c
drivers/gpu/drm/i915/intel_memory_region.h
drivers/gpu/drm/i915/selftests/intel_memory_region.c