Mesa (master): winsys/amdgpu: remove exported buffers from the cache
Marek Olšák
mareko at kemper.freedesktop.org
Thu Sep 3 16:59:14 UTC 2015
Module: Mesa
Branch: master
Commit: 54964c77510b060806615c842692c0f393e807e6
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=54964c77510b060806615c842692c0f393e807e6
Author: Marek Olšák <marek.olsak at amd.com>
Date: Tue Sep 1 04:14:33 2015 +0200
winsys/amdgpu: remove exported buffers from the cache
Cc: 11.0 <mesa-stable at lists.freedesktop.org>
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
---
src/gallium/winsys/amdgpu/drm/amdgpu_bo.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c b/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
index 50c42e3..fe55dc3 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
@@ -684,6 +684,9 @@ static boolean amdgpu_bo_get_handle(struct pb_buffer *buffer,
enum amdgpu_bo_handle_type type;
int r;
+ if ((void*)bo != (void*)buffer)
+ pb_cache_manager_remove_buffer(buffer);
+
switch (whandle->type) {
case DRM_API_HANDLE_TYPE_SHARED:
type = amdgpu_bo_handle_type_gem_flink_name;
More information about the mesa-commit
mailing list