All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu/userq: remove unnecessary NULL check
@ 2025-04-30  8:05 Dan Carpenter
  2025-04-30  9:28 ` Sharma, Shashank
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Dan Carpenter @ 2025-04-30  8:05 UTC (permalink / raw)
  To: Alex Deucher
  Cc: Christian König, David Airlie, Simona Vetter,
	Shashank Sharma, Sunil Khatri, Arvind Yadav,
	Arunpravin Paneer Selvam, amd-gfx, dri-devel, linux-kernel,
	kernel-janitors

The "ticket" pointer points to in the middle of the &exec struct so it
can't be NULL.  Remove the check.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
index b0e8098a3988..7505d920fb3d 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_userq.c
@@ -631,7 +631,7 @@ amdgpu_userq_validate_bos(struct amdgpu_userq_mgr *uq_mgr)
 			clear = false;
 			unlock = true;
 		/* The caller is already holding the reservation lock */
-		} else if (ticket && dma_resv_locking_ctx(resv) == ticket) {
+		} else if (dma_resv_locking_ctx(resv) == ticket) {
 			clear = false;
 			unlock = false;
 		/* Somebody else is using the BO right now */
-- 
2.47.2


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2025-05-01 13:05 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-30  8:05 [PATCH] drm/amdgpu/userq: remove unnecessary NULL check Dan Carpenter
2025-04-30  9:28 ` Sharma, Shashank
2025-04-30  9:49   ` Dan Carpenter
2025-04-30 12:50     ` Sharma, Shashank
2025-04-30 12:35   ` Christian König
2025-04-30 12:52     ` Sharma, Shashank
2025-04-30 12:28 ` Christian König
2025-04-30 14:20 ` Alex Deucher

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.