summaryrefslogtreecommitdiff
path: root/src/sna
diff options
context:
space:
mode:
Diffstat (limited to 'src/sna')
-rw-r--r--src/sna/kgem.c6
-rw-r--r--src/sna/kgem.h4
2 files changed, 8 insertions, 2 deletions
diff --git a/src/sna/kgem.c b/src/sna/kgem.c
index 825caa76..568d1200 100644
--- a/src/sna/kgem.c
+++ b/src/sna/kgem.c
@@ -1763,9 +1763,13 @@ bool __kgem_is_idle(struct kgem *kgem)
assert(!list_is_empty(&kgem->requests));
rq = list_last_entry(&kgem->requests, struct kgem_request, list);
- if (kgem_busy(kgem, rq->bo->handle))
+ if (kgem_busy(kgem, rq->bo->handle)) {
+ DBG(("%s: last requests handle=%d still busy\n",
+ __FUNCTION__, rq->bo->handle));
return false;
+ }
+ DBG(("%s: gpu idle\n", __FUNCTION__));
kgem_retire__requests(kgem);
assert(list_is_empty(&kgem->requests));
return true;
diff --git a/src/sna/kgem.h b/src/sna/kgem.h
index d085a2f0..d8018b80 100644
--- a/src/sna/kgem.h
+++ b/src/sna/kgem.h
@@ -261,8 +261,10 @@ bool kgem_retire(struct kgem *kgem);
bool __kgem_is_idle(struct kgem *kgem);
static inline bool kgem_is_idle(struct kgem *kgem)
{
- if (list_is_empty(&kgem->requests))
+ if (list_is_empty(&kgem->requests)) {
+ DBG(("%s: no outstanding requests\n", __FUNCTION__));
return true;
+ }
return __kgem_is_idle(kgem);
}