mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] gpu: ttm: add __releases function
@ 2019-11-26 10:13 Jules Irenge
  0 siblings, 0 replies; only message in thread
From: Jules Irenge @ 2019-11-26 10:13 UTC (permalink / raw)
  To: christian.koenig
  Cc: ray.huang, airlied, daniel, dri-devel, linux-kernel, Boqun.Feng,
	Andrea.Parri, Jules Irenge

Add releases() function to fix context imbalance.
 Issue detected by sparse tool.
warning: context imbalance in ttm_bo_cleanup_refs - unexpected unlock

Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
---
 drivers/gpu/drm/ttm/ttm_bo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c
index 98819462f025..c87481d667a9 100644
--- a/drivers/gpu/drm/ttm/ttm_bo.c
+++ b/drivers/gpu/drm/ttm/ttm_bo.c
@@ -544,7 +544,7 @@ static void ttm_bo_cleanup_refs_or_queue(struct ttm_buffer_object *bo)
 
 static int ttm_bo_cleanup_refs(struct ttm_buffer_object *bo,
 			       bool interruptible, bool no_wait_gpu,
-			       bool unlock_resv)
+			       bool unlock_resv) __releases(&glob->lru_lock)
 {
 	struct ttm_bo_global *glob = bo->bdev->glob;
 	struct dma_resv *resv;
-- 
2.23.0


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-11-26 10:13 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-26 10:13 [PATCH] gpu: ttm: add __releases function Jules Irenge

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®