]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.19-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 24 Nov 2023 14:35:26 +0000 (14:35 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 24 Nov 2023 14:35:26 +0000 (14:35 +0000)
added patches:
drm-amdgpu-fix-error-handling-in-amdgpu_bo_list_get.patch

queue-4.19/drm-amdgpu-fix-error-handling-in-amdgpu_bo_list_get.patch [new file with mode: 0644]
queue-4.19/series

diff --git a/queue-4.19/drm-amdgpu-fix-error-handling-in-amdgpu_bo_list_get.patch b/queue-4.19/drm-amdgpu-fix-error-handling-in-amdgpu_bo_list_get.patch
new file mode 100644 (file)
index 0000000..b38cab7
--- /dev/null
@@ -0,0 +1,35 @@
+From 12f76050d8d4d10dab96333656b821bd4620d103 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Christian=20K=C3=B6nig?= <christian.koenig@amd.com>
+Date: Thu, 9 Nov 2023 10:12:39 +0100
+Subject: drm/amdgpu: fix error handling in amdgpu_bo_list_get()
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Christian König <christian.koenig@amd.com>
+
+commit 12f76050d8d4d10dab96333656b821bd4620d103 upstream.
+
+We should not leak the pointer where we couldn't grab the reference
+on to the caller because it can be that the error handling still
+tries to put the reference then.
+
+Signed-off-by: Christian König <christian.koenig@amd.com>
+Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+Cc: stable@vger.kernel.org
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c
++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c
+@@ -168,6 +168,7 @@ int amdgpu_bo_list_get(struct amdgpu_fpr
+       }
+       rcu_read_unlock();
++      *result = NULL;
+       return -ENOENT;
+ }
index 745d0b8c5ea074159326ae09af2eb89c92284ec5..9c8df15ca5bd1469a09d2aae42d08eb4d0387871 100644 (file)
@@ -91,3 +91,4 @@ ext4-apply-umask-if-acl-support-is-disabled.patch
 ext4-correct-offset-of-gdb-backup-in-non-meta_bg-group-to-update_backups.patch
 ext4-correct-return-value-of-ext4_convert_meta_bg.patch
 ext4-remove-gdb-backup-copy-for-meta-bg-in-setup_new_flex_group_blocks.patch
+drm-amdgpu-fix-error-handling-in-amdgpu_bo_list_get.patch