sparse cleanups. s/0/NULL/ and mark a few things static.
This commit is contained in:
parent
c65fde5343
commit
aa74468aa5
12
exa/exa.c
12
exa/exa.c
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -195,7 +195,7 @@ exaOffscreenAlloc (ScreenPtr pScreen, int size, int align,
|
|||
new_area->offset = area->offset + real_size;
|
||||
new_area->size = area->size - real_size;
|
||||
new_area->state = ExaOffscreenAvail;
|
||||
new_area->save = 0;
|
||||
new_area->save = NULL;
|
||||
new_area->score = 0;
|
||||
new_area->next = area->next;
|
||||
area->next = new_area;
|
||||
|
@ -299,14 +299,14 @@ exaOffscreenFree (ScreenPtr pScreen, ExaOffscreenArea *area)
|
|||
ExaOffscreenValidate (pScreen);
|
||||
|
||||
area->state = ExaOffscreenAvail;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->offset = area->save_offset;
|
||||
area->score = 0;
|
||||
/*
|
||||
* Find previous area
|
||||
*/
|
||||
if (area == pExaScr->info->card.offScreenAreas)
|
||||
prev = 0;
|
||||
prev = NULL;
|
||||
else
|
||||
for (prev = pExaScr->info->card.offScreenAreas; prev; prev = prev->next)
|
||||
if (prev->next == area)
|
||||
|
@ -367,7 +367,7 @@ exaOffscreenInit (ScreenPtr pScreen)
|
|||
area->state = ExaOffscreenAvail;
|
||||
area->offset = pExaScr->info->card.offScreenBase;
|
||||
area->size = pExaScr->info->card.memorySize - area->offset;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->next = NULL;
|
||||
area->score = 0;
|
||||
|
||||
|
|
|
@ -507,10 +507,10 @@ exaComposite(CARD8 op,
|
|||
return;
|
||||
|
||||
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, 0,
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, NULL,
|
||||
REGION_RECTS(®ion), REGION_NUM_RECTS(®ion),
|
||||
xSrc - xDst, ySrc - yDst,
|
||||
FALSE, FALSE, 0, 0);
|
||||
FALSE, FALSE, 0, NULL);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -724,7 +724,7 @@ exaGlyphs (CARD8 op,
|
|||
{
|
||||
CompositePicture (PictOpAdd,
|
||||
pPicture,
|
||||
None,
|
||||
NULL,
|
||||
pMask,
|
||||
0, 0,
|
||||
0, 0,
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
#define STRACE
|
||||
#define TRACE
|
||||
|
||||
int exaGeneration;
|
||||
static int exaGeneration;
|
||||
int exaScreenPrivateIndex;
|
||||
int exaPixmapPrivateIndex;
|
||||
|
||||
|
@ -746,7 +746,7 @@ exaCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, GCPtr pGC,
|
|||
|
||||
return fbDoCopy (pSrcDrawable, pDstDrawable, pGC,
|
||||
srcx, srcy, width, height,
|
||||
dstx, dsty, exaCopyNtoN, 0, 0);
|
||||
dstx, dsty, exaCopyNtoN, 0, NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -963,7 +963,7 @@ exaImageGlyphBlt (DrawablePtr pDrawable,
|
|||
ExaCheckImageGlyphBlt(pDrawable, pGC, x, y, nglyph, ppciInit, pglyphBase);
|
||||
return;
|
||||
}
|
||||
glyph = 0;
|
||||
glyph = NULL;
|
||||
fbGetDrawable (pDrawable, dst, dstStride, dstBpp, dstXoff, dstYoff);
|
||||
switch (dstBpp) {
|
||||
case 8: glyph = fbGlyph8; break;
|
||||
|
@ -1096,7 +1096,7 @@ exaValidateGC (GCPtr pGC, Mask changes, DrawablePtr pDrawable)
|
|||
pGC->ops = (GCOps *) &exaAsyncPixmapGCOps;
|
||||
}
|
||||
|
||||
GCFuncs exaGCFuncs = {
|
||||
static GCFuncs exaGCFuncs = {
|
||||
exaValidateGC,
|
||||
miChangeGC,
|
||||
miCopyGC,
|
||||
|
@ -1149,8 +1149,8 @@ exaCopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
|
|||
#endif
|
||||
|
||||
fbCopyRegion (&pPixmap->drawable, &pPixmap->drawable,
|
||||
0,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, 0);
|
||||
NULL,
|
||||
&rgnDst, dx, dy, exaCopyNtoN, 0, NULL);
|
||||
|
||||
REGION_UNINIT(pWin->drawable.pScreen, &rgnDst);
|
||||
}
|
||||
|
|
|
@ -195,7 +195,7 @@ exaOffscreenAlloc (ScreenPtr pScreen, int size, int align,
|
|||
new_area->offset = area->offset + real_size;
|
||||
new_area->size = area->size - real_size;
|
||||
new_area->state = ExaOffscreenAvail;
|
||||
new_area->save = 0;
|
||||
new_area->save = NULL;
|
||||
new_area->score = 0;
|
||||
new_area->next = area->next;
|
||||
area->next = new_area;
|
||||
|
@ -299,14 +299,14 @@ exaOffscreenFree (ScreenPtr pScreen, ExaOffscreenArea *area)
|
|||
ExaOffscreenValidate (pScreen);
|
||||
|
||||
area->state = ExaOffscreenAvail;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->offset = area->save_offset;
|
||||
area->score = 0;
|
||||
/*
|
||||
* Find previous area
|
||||
*/
|
||||
if (area == pExaScr->info->card.offScreenAreas)
|
||||
prev = 0;
|
||||
prev = NULL;
|
||||
else
|
||||
for (prev = pExaScr->info->card.offScreenAreas; prev; prev = prev->next)
|
||||
if (prev->next == area)
|
||||
|
@ -367,7 +367,7 @@ exaOffscreenInit (ScreenPtr pScreen)
|
|||
area->state = ExaOffscreenAvail;
|
||||
area->offset = pExaScr->info->card.offScreenBase;
|
||||
area->size = pExaScr->info->card.memorySize - area->offset;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->next = NULL;
|
||||
area->score = 0;
|
||||
|
||||
|
|
|
@ -507,10 +507,10 @@ exaComposite(CARD8 op,
|
|||
return;
|
||||
|
||||
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, 0,
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, NULL,
|
||||
REGION_RECTS(®ion), REGION_NUM_RECTS(®ion),
|
||||
xSrc - xDst, ySrc - yDst,
|
||||
FALSE, FALSE, 0, 0);
|
||||
FALSE, FALSE, 0, NULL);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -724,7 +724,7 @@ exaGlyphs (CARD8 op,
|
|||
{
|
||||
CompositePicture (PictOpAdd,
|
||||
pPicture,
|
||||
None,
|
||||
NULL,
|
||||
pMask,
|
||||
0, 0,
|
||||
0, 0,
|
||||
|
|
|
@ -195,7 +195,7 @@ exaOffscreenAlloc (ScreenPtr pScreen, int size, int align,
|
|||
new_area->offset = area->offset + real_size;
|
||||
new_area->size = area->size - real_size;
|
||||
new_area->state = ExaOffscreenAvail;
|
||||
new_area->save = 0;
|
||||
new_area->save = NULL;
|
||||
new_area->score = 0;
|
||||
new_area->next = area->next;
|
||||
area->next = new_area;
|
||||
|
@ -299,14 +299,14 @@ exaOffscreenFree (ScreenPtr pScreen, ExaOffscreenArea *area)
|
|||
ExaOffscreenValidate (pScreen);
|
||||
|
||||
area->state = ExaOffscreenAvail;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->offset = area->save_offset;
|
||||
area->score = 0;
|
||||
/*
|
||||
* Find previous area
|
||||
*/
|
||||
if (area == pExaScr->info->card.offScreenAreas)
|
||||
prev = 0;
|
||||
prev = NULL;
|
||||
else
|
||||
for (prev = pExaScr->info->card.offScreenAreas; prev; prev = prev->next)
|
||||
if (prev->next == area)
|
||||
|
@ -367,7 +367,7 @@ exaOffscreenInit (ScreenPtr pScreen)
|
|||
area->state = ExaOffscreenAvail;
|
||||
area->offset = pExaScr->info->card.offScreenBase;
|
||||
area->size = pExaScr->info->card.memorySize - area->offset;
|
||||
area->save = 0;
|
||||
area->save = NULL;
|
||||
area->next = NULL;
|
||||
area->score = 0;
|
||||
|
||||
|
|
|
@ -507,10 +507,10 @@ exaComposite(CARD8 op,
|
|||
return;
|
||||
|
||||
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, 0,
|
||||
exaCopyNtoN (pSrc->pDrawable, pDst->pDrawable, NULL,
|
||||
REGION_RECTS(®ion), REGION_NUM_RECTS(®ion),
|
||||
xSrc - xDst, ySrc - yDst,
|
||||
FALSE, FALSE, 0, 0);
|
||||
FALSE, FALSE, 0, NULL);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -724,7 +724,7 @@ exaGlyphs (CARD8 op,
|
|||
{
|
||||
CompositePicture (PictOpAdd,
|
||||
pPicture,
|
||||
None,
|
||||
NULL,
|
||||
pMask,
|
||||
0, 0,
|
||||
0, 0,
|
||||
|
|
Loading…
Reference in New Issue