This is a note to let you know that I've just added the patch titled drm/i915: avoid uninitialised var in eb_parse() to the 5.10-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: drm-i915-avoid-uninitialised-var-in-eb_parse.patch and it can be found in the queue-5.10 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From jsg@xxxxxxxxx Mon Aug 9 13:47:05 2021 From: Jonathan Gray <jsg@xxxxxxxxx> Date: Mon, 9 Aug 2021 21:30:22 +1000 Subject: drm/i915: avoid uninitialised var in eb_parse() To: stable@xxxxxxxxxxxxxxx Cc: jason@xxxxxxxxxxxxxx Message-ID: <20210809113022.49484-1-jsg@xxxxxxxxx> From: Jonathan Gray <jsg@xxxxxxxxx> The backport of c9d9fdbc108af8915d3f497bbdf3898bf8f321b8 to 5.10 in 6976f3cf34a1a8b791c048bbaa411ebfe48666b1 removed more than it should have leading to 'batch' being used uninitialised. The 5.13 backport and the mainline commit did not remove the portion this patch adds back. Signed-off-by: Jonathan Gray <jsg@xxxxxxxxx> Fixes: 6976f3cf34a1 ("drm/i915: Revert "drm/i915/gem: Asynchronous cmdparser"") Cc: <stable@xxxxxxxxxxxxxxx> # 5.10 Cc: Jason Ekstrand <jason@xxxxxxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 7 +++++++ 1 file changed, 7 insertions(+) --- a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c +++ b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c @@ -2351,6 +2351,12 @@ static int eb_parse(struct i915_execbuff eb->batch_flags |= I915_DISPATCH_SECURE; } + batch = eb_dispatch_secure(eb, shadow); + if (IS_ERR(batch)) { + err = PTR_ERR(batch); + goto err_trampoline; + } + err = intel_engine_cmd_parser(eb->engine, eb->batch->vma, eb->batch_start_offset, @@ -2377,6 +2383,7 @@ secure_batch: err_unpin_batch: if (batch) i915_vma_unpin(batch); +err_trampoline: if (trampoline) i915_vma_unpin(trampoline); err_shadow: Patches currently in stable-queue which might be from jsg@xxxxxxxxx are queue-5.10/drm-i915-avoid-uninitialised-var-in-eb_parse.patch