summaryrefslogtreecommitdiff
path: root/src/i830.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2010-06-07 00:20:35 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2010-06-07 00:20:35 +0100
commitd56ea7a852d7090360fe080acec268de55ee908d (patch)
tree3257315dbb35fd85660d82045e57f89d0d7e556b /src/i830.h
parent8700673157fdd3a87ad5150f2f30823261fec519 (diff)
Use the direct dixGevPrivate() API when available
This is quicker and smaller than the old indirect function call to dixLookupPrivate(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/i830.h')
-rw-r--r--src/i830.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/i830.h b/src/i830.h
index ea4f2c40..4e24c779 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -162,7 +162,11 @@ extern int uxa_pixmap_index;
static inline struct intel_pixmap *i830_get_pixmap_intel(PixmapPtr pixmap)
{
+#if HAS_DEVPRIVATEKEYREC
+ return dixGetPrivate(&pixmap->devPrivates, &uxa_pixmap_index);
+#else
return dixLookupPrivate(&pixmap->devPrivates, &uxa_pixmap_index);
+#endif
}
static inline void i830_set_pixmap_intel(PixmapPtr pixmap, struct intel_pixmap *intel)