[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1642515391-19329-1-git-send-email-lyz_cs@pku.edu.cn>
Date: Tue, 18 Jan 2022 06:16:31 -0800
From: Yongzhi Liu <lyz_cs@....edu.cn>
To: l.stach@...gutronix.de, linux+etnaviv@...linux.org.uk,
christian.gmeiner@...il.com, airlied@...ux.ie, daniel@...ll.ch,
etnaviv@...ts.freedesktop.org
Cc: dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
Yongzhi Liu <lyz_cs@....edu.cn>
Subject: [PATCH] drm/etnaviv: Add missing pm_runtime_put
pm_runtime_get_sync() increments the runtime PM usage counter even
when it returns an error code, thus a matching decrement is needed
on the error handling path to keep the counter balanced.
Signed-off-by: Yongzhi Liu <lyz_cs@....edu.cn>
---
drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
index 242a5fd..5e81a98 100644
--- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
+++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
@@ -1714,6 +1714,9 @@ static int etnaviv_gpu_bind(struct device *dev, struct device *master,
return 0;
out_sched:
+#ifdef CONFIG_PM
+ pm_runtime_put_autosuspend(gpu->dev);
+#endif
etnaviv_sched_fini(gpu);
out_workqueue:
--
2.7.4
Powered by blists - more mailing lists