dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/nouveau/fifo: small cleanup in nvkm_chan_cctx_get()
@ 2022-11-15 13:16 Dan Carpenter
  0 siblings, 0 replies; 3+ messages in thread
From: Dan Carpenter @ 2022-11-15 13:16 UTC (permalink / raw)
  To: Ben Skeggs; +Cc: Karol Herbst, nouveau, kernel-janitors, dri-devel, Dave Airlie

The "&chan->cgrp->mutex" and "&cgrp->mutex" variables refer to the same
thing.  Use "&cgrp->mutex" consistently.

Signed-off-by: Dan Carpenter <error27@gmail.com>
---
 drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
index b7c9d6115bce..790b73ee5272 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
@@ -105,7 +105,7 @@ nvkm_chan_cctx_get(struct nvkm_chan *chan, struct nvkm_engn *engn, struct nvkm_c
 	if (cctx) {
 		refcount_inc(&cctx->refs);
 		*pcctx = cctx;
-		mutex_unlock(&chan->cgrp->mutex);
+		mutex_unlock(&cgrp->mutex);
 		return 0;
 	}
 
-- 
2.35.1


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

* [PATCH] drm/nouveau/fifo: small cleanup in nvkm_chan_cctx_get()
@ 2025-04-30  8:06 Dan Carpenter
  2025-05-16 14:10 ` Danilo Krummrich
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Carpenter @ 2025-04-30  8:06 UTC (permalink / raw)
  To: Lyude Paul
  Cc: Danilo Krummrich, David Airlie, Simona Vetter, dri-devel, nouveau,
	linux-kernel, kernel-janitors

"&chan->cgrp->mutex" and "&cgrp->mutex" are the same thing.  Use
"&cgrp->mutex" consistently.  It looks nicer and it silences a
Smatch static checker warning.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
 drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
index 7d4716dcd512..f5cd7f7c48b4 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chan.c
@@ -104,7 +104,7 @@ nvkm_chan_cctx_get(struct nvkm_chan *chan, struct nvkm_engn *engn, struct nvkm_c
 	if (cctx) {
 		refcount_inc(&cctx->refs);
 		*pcctx = cctx;
-		mutex_unlock(&chan->cgrp->mutex);
+		mutex_unlock(&cgrp->mutex);
 		return 0;
 	}
 
-- 
2.47.2


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

* Re: [PATCH] drm/nouveau/fifo: small cleanup in nvkm_chan_cctx_get()
  2025-04-30  8:06 [PATCH] drm/nouveau/fifo: small cleanup in nvkm_chan_cctx_get() Dan Carpenter
@ 2025-05-16 14:10 ` Danilo Krummrich
  0 siblings, 0 replies; 3+ messages in thread
From: Danilo Krummrich @ 2025-05-16 14:10 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: Lyude Paul, David Airlie, Simona Vetter, dri-devel, nouveau,
	linux-kernel, kernel-janitors

On 4/30/25 10:06 AM, Dan Carpenter wrote:
> "&chan->cgrp->mutex" and "&cgrp->mutex" are the same thing.  Use
> "&cgrp->mutex" consistently.  It looks nicer and it silences a
> Smatch static checker warning.

Applied to drm-misc-next, thanks!

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

end of thread, other threads:[~2025-05-16 14:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-30  8:06 [PATCH] drm/nouveau/fifo: small cleanup in nvkm_chan_cctx_get() Dan Carpenter
2025-05-16 14:10 ` Danilo Krummrich
  -- strict thread matches above, loose matches on Subject: below --
2022-11-15 13:16 Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).