projects
/
profile
/
ivi
/
libdrm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd16d96
)
use linux kernel macros don't make our own
author
Dave Airlie
<airlied@linux.ie>
Sun, 25 Sep 2005 03:09:51 +0000
(
03:09
+0000)
committer
Dave Airlie
<airlied@linux.ie>
Sun, 25 Sep 2005 03:09:51 +0000
(
03:09
+0000)
linux-core/drmP.h
patch
|
blob
|
history
diff --git
a/linux-core/drmP.h
b/linux-core/drmP.h
index
81c542d
..
bdbb0d9
100644
(file)
--- a/
linux-core/drmP.h
+++ b/
linux-core/drmP.h
@@
-215,9
+215,9
@@
/** \name Internal types and structures */
/*@{*/
-#define DRM_ARRAY_SIZE(x)
(sizeof(x)/sizeof(x[0])
)
-#define DRM_MIN(a,b)
((a)<(b)?(a):(b)
)
-#define DRM_MAX(a,b)
((a)>(b)?(a):(b)
)
+#define DRM_ARRAY_SIZE(x)
ARRAY_SIZE(x
)
+#define DRM_MIN(a,b)
min(a,b
)
+#define DRM_MAX(a,b)
max(a,b
)
#define DRM_LEFTCOUNT(x) (((x)->rp + (x)->count - (x)->wp) % ((x)->count + 1))
#define DRM_BUFCOUNT(x) ((x)->count - DRM_LEFTCOUNT(x))