All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] typdef uintptr_t drm_handle_t; unsigned int is wrong on 64-bit.
@ 2010-04-03  1:59 Matthew W. S. Bell
  2010-04-03  7:49 ` Dave Airlie
  0 siblings, 1 reply; 15+ messages in thread
From: Matthew W. S. Bell @ 2010-04-03  1:59 UTC (permalink / raw)
  To: dri-devel


[-- Attachment #1.1: Type: text/plain, Size: 968 bytes --]

From d457b05faabde1a51b8e4b8f6fc13af9f07809f8 Mon Sep 17 00:00:00 2001

drm_handle_t appears to be assigned values from void*. As such unsigned
int is certainly not the same size on 64-bit. Convert to uintptr_t in
all cases as it is defined for this purpose.

I fear this patch changes ABI, but I am not sure.

Matthew W.S. Bell

---
 include/drm/drm.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/drm/drm.h b/include/drm/drm.h
index 4822159..95141a2 100644
--- a/include/drm/drm.h
+++ b/include/drm/drm.h
@@ -40,7 +40,7 @@
 
 #include <linux/types.h>
 #include <asm/ioctl.h>
-typedef unsigned int drm_handle_t;
+typedef uintptr_t drm_handle_t;
 
 #else /* One of the BSDs */
 
@@ -54,7 +54,7 @@ typedef int32_t  __s32;
 typedef uint32_t __u32;
 typedef int64_t  __s64;
 typedef uint64_t __u64;
-typedef unsigned long drm_handle_t;
+typedef uintptr_t drm_handle_t;
 
 #endif
 
-- 
1.7.0



[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

[-- Attachment #2: Type: text/plain, Size: 345 bytes --]

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev

[-- Attachment #3: Type: text/plain, Size: 161 bytes --]

--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2010-04-14 17:37 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-03  1:59 [PATCH] typdef uintptr_t drm_handle_t; unsigned int is wrong on 64-bit Matthew W. S. Bell
2010-04-03  7:49 ` Dave Airlie
2010-04-03 13:09   ` Matthew W. S. Bell
2010-04-05  7:46     ` Dave Airlie
2010-04-06 20:14       ` Robert Noland
2010-04-09  2:05       ` [PATCH] drm_handle_t type Matthew W. S. Bell
2010-04-10 18:30       ` Matthew W. S. Bell
2010-04-11 14:10         ` Robert Noland
2010-04-13 23:19           ` Matthew W. S. Bell
2010-04-14  3:26             ` Robert Noland
2010-04-14  3:32             ` Robert Noland
2010-04-14  3:46               ` Dave Airlie
2010-04-14 17:36                 ` Robert Noland
2010-04-14 16:15               ` Matthew W. S. Bell
2010-04-03 21:57   ` [PATCH] typdef uintptr_t drm_handle_t; unsigned int is wrong on 64-bit Matthew W. S. Bell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.