projects
/
profile
/
ivi
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cad87eb
)
r300g: fix buffer reuse issue caused by previous commit
author
Dave Airlie
<airlied@redhat.com>
Wed, 15 Sep 2010 10:58:14 +0000
(20:58 +1000)
committer
Marek Olšák
<maraeo@gmail.com>
Wed, 15 Sep 2010 11:26:04 +0000
(13:26 +0200)
caused by
0b9eb5c9bb03e5134d9a41786178100109e80c5a
test run glxgears, resize.
src/gallium/winsys/radeon/drm/radeon_drm_buffer.c
patch
|
blob
|
history
diff --git
a/src/gallium/winsys/radeon/drm/radeon_drm_buffer.c
b/src/gallium/winsys/radeon/drm/radeon_drm_buffer.c
index
46e8df7
..
cf66524
100644
(file)
--- a/
src/gallium/winsys/radeon/drm/radeon_drm_buffer.c
+++ b/
src/gallium/winsys/radeon/drm/radeon_drm_buffer.c
@@
-56,15
+56,18
@@
static void
radeon_drm_buffer_destroy(struct pb_buffer *_buf)
{
struct radeon_drm_buffer *buf = radeon_drm_buffer(_buf);
+ int name;
if (buf->bo->ptr != NULL) {
remove_from_list(buf);
radeon_bo_unmap(buf->bo);
buf->bo->ptr = NULL;
}
-
- util_hash_table_remove(buf->mgr->buffer_handles,
- (void*)(uintptr_t)buf->bo->handle);
+ name = radeon_gem_name_bo(buf->bo);
+ if (name) {
+ util_hash_table_remove(buf->mgr->buffer_handles,
+ (void*)(uintptr_t)name);
+ }
radeon_bo_unref(buf->bo);
FREE(buf);