panfrost: Implement panfrost_bo_cache_evict_all

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
This commit is contained in:
Alyssa Rosenzweig 2019-07-15 09:17:12 -07:00
parent f02278ae87
commit 48f51e9dbb
1 changed files with 9 additions and 1 deletions

View File

@ -127,7 +127,15 @@ void
panfrost_bo_cache_evict_all(
struct panfrost_screen *screen)
{
/* Stub */
for (unsigned i = 0; i < ARRAY_SIZE(screen->bo_cache); ++i) {
struct list_head *bucket = &screen->bo_cache[i];
list_for_each_entry_safe(struct panfrost_bo, entry, bucket, link) {
list_del(&entry->link);
panfrost_drm_release_bo(screen, entry, false);
}
}
return;
}