diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2012-04-09 22:53:31 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2012-04-10 12:07:12 +0100 |
commit | 333fdcad8677675a4758223c1a980c90d970ee42 (patch) | |
tree | a95e56c7d9e42f653647bb8bf6f367dc17a5de05 /src | |
parent | 778232e3d2fb5340a3092014801dc00a56c56d42 (diff) |
sna: Repeat expire whilst there remaining outstanding requests
Do not allow the cache expiration to finish if we are still running
requests.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src')
-rw-r--r-- | src/sna/kgem.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sna/kgem.c b/src/sna/kgem.c index dde9d1d4..6dd1871e 100644 --- a/src/sna/kgem.c +++ b/src/sna/kgem.c @@ -1979,7 +1979,7 @@ bool kgem_expire_cache(struct kgem *kgem) time(&now); expire = 0; - idle = true; + idle = !kgem->need_retire; for (i = 0; i < ARRAY_SIZE(kgem->inactive); i++) { idle &= list_is_empty(&kgem->inactive[i]); list_for_each_entry(bo, &kgem->inactive[i], list) { @@ -1999,7 +1999,7 @@ bool kgem_expire_cache(struct kgem *kgem) if (expire == 0) return true; - idle = true; + idle = !kgem->need_retire; for (i = 0; i < ARRAY_SIZE(kgem->inactive); i++) { struct list preserve; |