From d2698d30377ded3f817f90cf2f17d9d3cda5a855 Mon Sep 17 00:00:00 2001 From: marha Date: Sat, 10 Jul 2010 15:23:23 +0000 Subject: git update 10/7/2010 --- libX11/specs/xmlrules.in | 8 ++++---- xorg-server/hw/xfree86/dri2/dri2.c | 19 ++++++++++++++++++- xorg-server/mi/miscrinit.c | 2 +- xorg-server/xkbdata.src/rules/base.xml.in | 1 + 4 files changed, 24 insertions(+), 6 deletions(-) diff --git a/libX11/specs/xmlrules.in b/libX11/specs/xmlrules.in index 50865b5b8..20263afba 100644 --- a/libX11/specs/xmlrules.in +++ b/libX11/specs/xmlrules.in @@ -44,16 +44,16 @@ CLEANFILES = $(spec_DATA) SUFFIXES = .xml .ps .pdf .txt .html -.xml.txt: +%.txt: %.xml $(dist_spec_DATA) $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) txt $< -.xml.html: +%.html: %.xml $(dist_spec_DATA) $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) xhtml-nochunks $< -.xml.pdf: +%.pdf: %.xml $(dist_spec_DATA) $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop pdf $< -.xml.ps: +%.ps: %.xml $(dist_spec_DATA) $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop ps $< endif HAVE_XMLTO diff --git a/xorg-server/hw/xfree86/dri2/dri2.c b/xorg-server/hw/xfree86/dri2/dri2.c index fbed587c2..9bf838e6c 100644 --- a/xorg-server/hw/xfree86/dri2/dri2.c +++ b/xorg-server/hw/xfree86/dri2/dri2.c @@ -82,6 +82,7 @@ typedef struct _DRI2Drawable { CARD64 last_swap_msc; /* msc at completion of most recent swap */ CARD64 last_swap_ust; /* ust at completion of most recent swap */ int swap_limit; /* for N-buffering */ + unsigned long serialNumber; } DRI2DrawableRec, *DRI2DrawablePtr; typedef struct _DRI2Screen { @@ -130,6 +131,19 @@ DRI2GetDrawable(DrawablePtr pDraw) } } +static unsigned long +DRI2DrawableSerial(DrawablePtr pDraw) +{ + ScreenPtr pScreen = pDraw->pScreen; + PixmapPtr pPix; + + if (pDraw->type != DRAWABLE_WINDOW) + return pDraw->serialNumber; + + pPix = pScreen->GetWindowPixmap((WindowPtr)pDraw); + return pPix->drawable.serialNumber; +} + static DRI2DrawablePtr DRI2AllocateDrawable(DrawablePtr pDraw) { @@ -163,6 +177,7 @@ DRI2AllocateDrawable(DrawablePtr pDraw) pPriv->last_swap_msc = 0; pPriv->last_swap_ust = 0; list_init(&pPriv->reference_list); + pPriv->serialNumber = DRI2DrawableSerial(pDraw); if (pDraw->type == DRAWABLE_WINDOW) { pWin = (WindowPtr) pDraw; @@ -326,6 +341,7 @@ allocate_or_reuse_buffer(DrawablePtr pDraw, DRI2ScreenPtr ds, || !dimensions_match || (pPriv->buffers[old_buf]->format != format)) { *buffer = (*ds->CreateBuffer)(pDraw, attachment, format); + pPriv->serialNumber = DRI2DrawableSerial(pDraw); return TRUE; } else { @@ -384,7 +400,8 @@ do_get_buffers(DrawablePtr pDraw, int *width, int *height, } dimensions_match = (pDraw->width == pPriv->width) - && (pDraw->height == pPriv->height); + && (pDraw->height == pPriv->height) + && (pPriv->serialNumber == DRI2DrawableSerial(pDraw)); buffers = malloc((count + 1) * sizeof(buffers[0])); diff --git a/xorg-server/mi/miscrinit.c b/xorg-server/mi/miscrinit.c index 60a983e65..6ac9090b2 100644 --- a/xorg-server/mi/miscrinit.c +++ b/xorg-server/mi/miscrinit.c @@ -76,7 +76,6 @@ miModifyPixmapHeader(PixmapPtr pPixmap, int width, int height, int depth, pPixmap->drawable.depth = depth; pPixmap->drawable.bitsPerPixel = bitsPerPixel; pPixmap->drawable.id = 0; - pPixmap->drawable.serialNumber = NEXT_SERIAL_NUMBER; pPixmap->drawable.x = 0; pPixmap->drawable.y = 0; pPixmap->drawable.width = width; @@ -116,6 +115,7 @@ miModifyPixmapHeader(PixmapPtr pPixmap, int width, int height, int depth, if (pPixData) pPixmap->devPrivate.ptr = pPixData; } + pPixmap->drawable.serialNumber = NEXT_SERIAL_NUMBER; return TRUE; } diff --git a/xorg-server/xkbdata.src/rules/base.xml.in b/xorg-server/xkbdata.src/rules/base.xml.in index 0372ed4a8..d23dbdc1b 100644 --- a/xorg-server/xkbdata.src/rules/base.xml.in +++ b/xorg-server/xkbdata.src/rules/base.xml.in @@ -1544,6 +1544,7 @@ <_shortDescription>Bel <_description>Belgium ger + nld fra -- cgit v1.2.3