Build fixes for EXA3

* EXA in xserver head now requires -DEXA_DRIVER_KNOWN_MAJOR=3
* EXA3 drops the UploadToScratch hook, so guard it for < 3 only.

Signed-off-by: Chris Ball <cjb@laptop.org>
This commit is contained in:
Chris Ball
2009-02-24 12:32:01 -05:00
parent e4f6a2fcd5
commit 7adc184e5e
4 changed files with 13 additions and 3 deletions

View File

@@ -99,6 +99,7 @@ fi
# technically this should be a configure flag. meh.
AC_DEFINE(XF86EXA, 1, [Build support for Exa])
AC_DEFINE(EXA_DRIVER_KNOWN_MAJOR, 3, [Major version of EXA we can handle])
SAVE_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $XORG_CFLAGS"

View File

@@ -1365,6 +1365,9 @@ SiS300AccelInit(ScreenPtr pScreen)
return FALSE;
}
#if EXA_VERSION_MAJOR < 3
/* UploadToScratch has been dropped in EXA version 3. */
/* Reserve locked offscreen scratch area of 128K for glyph data */
pSiS->exa_scratch = exaOffscreenAlloc(pScreen, 128 * 1024, 16, TRUE,
SiSScratchSave, pSiS);
@@ -1372,7 +1375,7 @@ SiS300AccelInit(ScreenPtr pScreen)
pSiS->exa_scratch_next = pSiS->exa_scratch->offset;
pSiS->EXADriverPtr->UploadToScratch = SiSUploadToScratch;
}
#endif
} else {
pSiS->NoXvideo = TRUE; /* No fbmem manager -> no xv */

View File

@@ -2399,6 +2399,9 @@ SiS315AccelInit(ScreenPtr pScreen)
return FALSE;
}
#if EXA_VERSION_MAJOR < 3
/* UploadToScratch has been dropped in EXA version 3. */
/* Reserve locked offscreen scratch area of 128K for glyph data */
pSiS->exa_scratch = exaOffscreenAlloc(pScreen, 128 * 1024, 16, TRUE,
SiSScratchSave, pSiS);
@@ -2406,7 +2409,7 @@ SiS315AccelInit(ScreenPtr pScreen)
pSiS->exa_scratch_next = pSiS->exa_scratch->offset;
pSiS->EXADriverPtr->UploadToScratch = SiSUploadToScratch;
}
#endif
} else {
pSiS->NoXvideo = TRUE; /* No fbmem manager -> no xv */

View File

@@ -880,6 +880,9 @@ SiSAccelInit(ScreenPtr pScreen)
return FALSE;
}
#if EXA_VERSION_MAJOR < 3
/* UploadToScratch has been dropped in EXA version 3. */
/* Reserve locked offscreen scratch area of 64K for glyph data */
pSiS->exa_scratch = exaOffscreenAlloc(pScreen, 64 * 1024, 16, TRUE,
SiSScratchSave, pSiS);
@@ -887,7 +890,7 @@ SiSAccelInit(ScreenPtr pScreen)
pSiS->exa_scratch_next = pSiS->exa_scratch->offset;
pSiS->EXADriverPtr->UploadToScratch = SiSUploadToScratch;
}
#endif
} else {
pSiS->NoXvideo = TRUE; /* No fbmem manager -> no xv */