drm/i915: Reserve some kernel space per vm
authorAndrzej Hajda <andrzej.hajda@intel.com>
Thu, 26 Oct 2023 18:36:26 +0000 (20:36 +0200)
committerAndrzej Hajda <andrzej.hajda@intel.com>
Tue, 31 Oct 2023 12:06:17 +0000 (13:06 +0100)
commit9bb66c179f50e61df20ba13c9b34ca17d00b05fb
tree0cbf2e2c23c2f4729b7feb2a431df910bf2a312f
parent8aa519f17512da50a2d850b60472de656e2b210a
drm/i915: Reserve some kernel space per vm

Reserve one page in each vm for kernel space to use for things
such as workarounds.

v2: use real memory, do not decrease vm.total
v4: reserve only one page and explain flag
v5: remove allocated object on ppgtt cleanup
v6: decrease vm->total by reservation size

Suggested-by: Chris Wilson <chris.p.wilson@linux.intel.com>
Signed-off-by: Andrzej Hajda <andrzej.hajda@intel.com>
Reviewed-by: Jonathan Cavitt <jonathan.cavitt@intel.com>
Reviewed-by: Nirmoy Das <nirmoy.das@intel.com>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231026-wabb-v6-1-4aa7d55d0a8a@intel.com
drivers/gpu/drm/i915/gt/gen8_ppgtt.c
drivers/gpu/drm/i915/gt/intel_gtt.h