Re: [Intel-gfx] [PATCH] drm/i915/ttm: ensure we release the intel_memory_region

2021-08-19 Thread Matthew Auld
On Thu, 19 Aug 2021 at 08:25, Thomas Hellström wrote: > > On Wed, 2021-08-18 at 18:12 +0100, Matthew Auld wrote: > > If the ttm_bo_init_reserved() call fails ensure we also release the > > region, otherwise we leak the reference, or worse hit some uaf, when > > we > > start using the objects.list.

Re: [PATCH] drm/i915/ttm: ensure we release the intel_memory_region

2021-08-19 Thread Thomas Hellström
On Wed, 2021-08-18 at 18:12 +0100, Matthew Auld wrote: > If the ttm_bo_init_reserved() call fails ensure we also release the > region, otherwise we leak the reference, or worse hit some uaf, when > we > start using the objects.list. Also remove the make_unshrinkable call > here, which doesn't do an

[PATCH] drm/i915/ttm: ensure we release the intel_memory_region

2021-08-18 Thread Matthew Auld
If the ttm_bo_init_reserved() call fails ensure we also release the region, otherwise we leak the reference, or worse hit some uaf, when we start using the objects.list. Also remove the make_unshrinkable call here, which doesn't do anything. Signed-off-by: Matthew Auld Cc: Thomas Hellström ---