summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2020-03-02 22:13:36 +0300
committerLucas Stach <l.stach@pengutronix.de>2020-03-03 12:58:57 +0300
commit78f2bfa3181cd7ee134274aa17177dd933c69dc1 (patch)
treebd0a1eb8d3634748a8e28194a09f38a82ec8bde1
parent1a910c11d35bfacb68a3e650fbc087491e92661f (diff)
downloadlinux-78f2bfa3181cd7ee134274aa17177dd933c69dc1.tar.xz
drm/etnaviv: Warn when GPU doesn't idle fast enough
If the GPU isn't idle after signalling pm_runtime_mark_last_busy() plus waiting for the autosuspend delay there's likely something wrong with the way we check idleness so warn about that. Signed-off-by: Guido Günther <agx@sigxcpu.org> Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
-rw-r--r--drivers/gpu/drm/etnaviv/etnaviv_gpu.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
index 26fe34086a60..169db7cc0ec6 100644
--- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
+++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
@@ -1839,8 +1839,11 @@ static int etnaviv_gpu_rpm_suspend(struct device *dev)
mask = gpu->idle_mask & ~(VIVS_HI_IDLE_STATE_FE |
VIVS_HI_IDLE_STATE_MC);
idle = gpu_read(gpu, VIVS_HI_IDLE_STATE) & mask;
- if (idle != mask)
+ if (idle != mask) {
+ dev_warn_ratelimited(dev, "GPU not yet idle, mask: 0x%08x\n",
+ idle);
return -EBUSY;
+ }
return etnaviv_gpu_hw_suspend(gpu);
}