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:
04521c1
)
r300g: typecast void* to unsigned correctly
author
Marek Olšák
<maraeo@gmail.com>
Sat, 12 Feb 2011 22:36:48 +0000
(23:36 +0100)
committer
Marek Olšák
<maraeo@gmail.com>
Sat, 12 Feb 2011 22:36:48 +0000
(23:36 +0100)
src/gallium/winsys/radeon/drm/radeon_drm_bo.c
patch
|
blob
|
history
diff --git
a/src/gallium/winsys/radeon/drm/radeon_drm_bo.c
b/src/gallium/winsys/radeon/drm/radeon_drm_bo.c
index
47d4f4d
..
2693043
100644
(file)
--- a/
src/gallium/winsys/radeon/drm/radeon_drm_bo.c
+++ b/
src/gallium/winsys/radeon/drm/radeon_drm_bo.c
@@
-314,14
+314,16
@@
static void radeon_bomgr_destroy(struct pb_manager *_mgr)
FREE(mgr);
}
+#define PTR_TO_UINT(x) ((unsigned)((intptr_t)(x) & 0xffffffff))
+
static unsigned handle_hash(void *key)
{
- return
(unsigned)key
;
+ return
PTR_TO_UINT(key)
;
}
static int handle_compare(void *key1, void *key2)
{
- return
!((int)key1 == (int)
key2);
+ return
PTR_TO_UINT(key1) == PTR_TO_UINT(
key2);
}
struct pb_manager *radeon_bomgr_create(struct radeon_drm_winsys *rws)