Skip to content
Snippets Groups Projects
Commit 8b3f2a9e authored by Rob Clark's avatar Rob Clark :speech_balloon: Committed by Marge Bot
Browse files

freedreno/drm: Fix potential bo cache vs export crash

Keep the list head valid (empty) after allocation from bo cache.  Avoids
a potential later crash in lookup_bo in the following sequence:

1. alloc, bo cache hit
2. export
3. re-import

Cc: mesa-stable
Fixes: f3cc0d27 ("freedreno: import libdrm_freedreno + redesign submit")
Closes: mesa/mesa#6988


Signed-off-by: default avatarRob Clark <robdclark@chromium.org>
Part-of: <mesa/mesa!17888>
parent 0a0205f0
No related branches found
No related tags found
No related merge requests found
......@@ -142,7 +142,7 @@ find_in_bucket(struct fd_bo_bucket *bucket, uint32_t flags)
break;
if (entry->alloc_flags == flags) {
bo = entry;
list_del(&bo->list);
list_delinit(&bo->list);
break;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment