summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaciej Cencora <[email protected]>2009-08-15 15:10:29 +0200
committerMaciej Cencora <[email protected]>2009-08-15 15:14:25 +0200
commitd2b1b9e8d5407e87fc2a6276568088115c28029f (patch)
tree3cebef9c2f094806a2f28f8622828ce924950d52
parentf3e1d7d6f81f1b84e5cf83a1c7118067ba670f79 (diff)
radeon: add flag for drm OQ support
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_screen.c12
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_screen.h1
2 files changed, 8 insertions, 5 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_screen.c b/src/mesa/drivers/dri/radeon/radeon_screen.c
index 7b759661ca7..c8d491621a8 100644
--- a/src/mesa/drivers/dri/radeon/radeon_screen.c
+++ b/src/mesa/drivers/dri/radeon/radeon_screen.c
@@ -999,6 +999,7 @@ radeonCreateScreen( __DRIscreenPrivate *sPriv )
screen->drmSupportsPointSprites = (sPriv->drm_version.minor >= 13);
screen->drmSupportsCubeMapsR100 = (sPriv->drm_version.minor >= 15);
screen->drmSupportsVertexProgram = (sPriv->drm_version.minor >= 25);
+ screen->drmSupportsOcclusionQueries = (sPriv->drm_version.minor >= 30);
}
ret = radeon_set_screen_flags(screen, dri_priv->deviceID);
@@ -1094,7 +1095,7 @@ radeonCreateScreen( __DRIscreenPrivate *sPriv )
/* +r6/r7 */
if(screen->chip_family >= CHIP_FAMILY_R600)
{
- if (ret)
+ if (ret)
{
FREE( screen );
fprintf(stderr, "Unable to get fb location need newer drm\n");
@@ -1107,18 +1108,18 @@ radeonCreateScreen( __DRIscreenPrivate *sPriv )
}
else
{
- if (ret)
+ if (ret)
{
if (screen->chip_family < CHIP_FAMILY_RS600 && !screen->kernel_mm)
screen->fbLocation = ( INREG( RADEON_MC_FB_LOCATION ) & 0xffff) << 16;
- else
+ else
{
FREE( screen );
fprintf(stderr, "Unable to get fb location need newer drm\n");
return NULL;
}
- }
- else
+ }
+ else
{
screen->fbLocation = (temp & 0xffff) << 16;
}
@@ -1298,6 +1299,7 @@ radeonCreateScreen2(__DRIscreenPrivate *sPriv)
screen->drmSupportsPointSprites = 1;
screen->drmSupportsCubeMapsR100 = 1;
screen->drmSupportsVertexProgram = 1;
+ screen->drmSupportsOcclusionQueries = 1;
screen->irq = 1;
ret = radeonGetParam(sPriv, RADEON_PARAM_DEVICE_ID, &device_id);
diff --git a/src/mesa/drivers/dri/radeon/radeon_screen.h b/src/mesa/drivers/dri/radeon/radeon_screen.h
index 2a2f6b1b0b8..f0dd46b0b13 100644
--- a/src/mesa/drivers/dri/radeon/radeon_screen.h
+++ b/src/mesa/drivers/dri/radeon/radeon_screen.h
@@ -99,6 +99,7 @@ typedef struct radeon_screen {
GLboolean drmSupportsPointSprites; /* need radeon kernel module >= 1.13 */
GLboolean drmSupportsCubeMapsR100; /* need radeon kernel module >= 1.15 */
GLboolean drmSupportsVertexProgram; /* need radeon kernel module >= 1.25 */
+ GLboolean drmSupportsOcclusionQueries; /* need radeon kernel module >= 1.30 */
GLboolean depthHasSurface;
/* Configuration cache with default values for all contexts */