]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gt: Onion unwind for scratch page allocation failure
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 19 Oct 2020 08:34:44 +0000 (09:34 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 19 Oct 2020 11:36:38 +0000 (12:36 +0100)
commiteb1b7e7521b006ce36319291af2ef232e0952395
treefb25595abd1739bab168198ce955e308dcf8d36e
parenta0ab050b89d4a1b11715bcf8267b3a876c153f75
drm/i915/gt: Onion unwind for scratch page allocation failure

In switching to using objects for our ppGTT scratch pages, care was not
taken to avoid trying to unref NULL objects on failure. And for gen6
ppGTT, it appears we forgot entirely to unwind after a partial allocation
failure.

Fixes: 0380a614c6ba ("drm/i915/gt: Switch to object allocations for page directories")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Matthew Auld <matthew.auld@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201019083444.1286-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/gen6_ppgtt.c
drivers/gpu/drm/i915/gt/gen8_ppgtt.c