summaryrefslogtreecommitdiff
path: root/uxa
diff options
context:
space:
mode:
authorZhigang Gong <zhigang.gong@linux.intel.com>2012-07-12 18:47:51 +0800
committerChris Wilson <chris@chris-wilson.co.uk>2012-07-12 12:46:06 +0100
commitfa89e0614563cbe0cc45e6d7e7584cb333244c27 (patch)
tree6a6808b4f3fad87d58ca25a8f67ab597ffde6301 /uxa
parentd25000e1f31e78aff2ab43adb12aec0aac36f56f (diff)
uxa/glyphs: Bypass uxa glyphs operations if using glamor.
glamor_glyphs will never fallback. We don't need to keep a uxa glyphs cache picture here. Thus simply bypass the corresponding operations. Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'uxa')
-rw-r--r--uxa/uxa-glyphs.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/uxa/uxa-glyphs.c b/uxa/uxa-glyphs.c
index 6bdf101b..527942ad 100644
--- a/uxa/uxa-glyphs.c
+++ b/uxa/uxa-glyphs.c
@@ -112,6 +112,9 @@ static void uxa_unrealize_glyph_caches(ScreenPtr pScreen)
uxa_screen_t *uxa_screen = uxa_get_screen(pScreen);
int i;
+ if (uxa_screen->info->flags & UXA_USE_GLAMOR)
+ return;
+
if (!uxa_screen->glyph_cache_initialized)
return;
@@ -211,6 +214,11 @@ bail:
Bool uxa_glyphs_init(ScreenPtr pScreen)
{
+
+ uxa_screen_t *uxa_screen = uxa_get_screen(pScreen);
+
+ if (uxa_screen->info->flags & UXA_USE_GLAMOR)
+ return TRUE;
#if HAS_DIXREGISTERPRIVATEKEY
if (!dixRegisterPrivateKey(&uxa_glyph_key, PRIVATE_GLYPH, 0))
return FALSE;
@@ -307,8 +315,10 @@ uxa_glyph_unrealize(ScreenPtr screen,
struct uxa_glyph *priv;
uxa_screen_t *uxa_screen = uxa_get_screen(screen);
- if (uxa_screen->info->flags & UXA_USE_GLAMOR)
+ if (uxa_screen->info->flags & UXA_USE_GLAMOR) {
glamor_glyph_unrealize(screen, glyph);
+ return;
+ }
/* Use Lookup in case we have not attached to this glyph. */
priv = dixLookupPrivate(&glyph->devPrivates, &uxa_glyph_key);