drm/i915/lmem: support optional CPU clearing for special internal use
authorMatthew Auld <matthew.auld@intel.com>
Thu, 29 Apr 2021 10:30:54 +0000 (11:30 +0100)
committerMatthew Auld <matthew.auld@intel.com>
Tue, 4 May 2021 09:58:56 +0000 (10:58 +0100)
commit4f869f1dbd7eac42f3d4b129b8c941de54de77bf
treee696cc6ac551f293dbc2f5be34e6a7e1a3681c90
parent2459e56fd8af0b47fcbfbdff2fdc02e4077680ec
drm/i915/lmem: support optional CPU clearing for special internal use

For some internal device local-memory objects it would be useful to have
an option to CPU clear the pages upon gathering the backing store. Note
that this might be before the blitter is useable, which is the case for
some internal GuC objects.

Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Lionel Landwerlin <lionel.g.landwerlin@linux.intel.com>
Cc: Jon Bloomfield <jon.bloomfield@intel.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Kenneth Graunke <kenneth@whitecape.org>
Cc: Jason Ekstrand <jason@jlekstrand.net>
Cc: Dave Airlie <airlied@gmail.com>
Cc: dri-devel@lists.freedesktop.org
Cc: mesa-dev@lists.freedesktop.org
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20210429103056.407067-7-matthew.auld@intel.com
drivers/gpu/drm/i915/gem/i915_gem_object_types.h
drivers/gpu/drm/i915/gem/i915_gem_region.c
drivers/gpu/drm/i915/selftests/intel_memory_region.c