summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i830
diff options
context:
space:
mode:
authorAlan Hourihane <[email protected]>2005-08-15 06:59:24 +0000
committerAlan Hourihane <[email protected]>2005-08-15 06:59:24 +0000
commitdabec11d277e68b6940e741651e61102767240b9 (patch)
tree12e8d6988b4b20a0d4fbcf4312ee89f66ddb1225 /src/mesa/drivers/dri/i830
parent69dc32cfac945bf664ddfbd6f0116404f893e66e (diff)
Add Egberts fixes for 64bit architectures
Add additional checks for the *DRIRec info structure passed in from the device driver. This ensures that things fallback to indirect rendering if the DDX driver has had modifications (i.e. removal of the drmAddress field).
Diffstat (limited to 'src/mesa/drivers/dri/i830')
-rw-r--r--src/mesa/drivers/dri/i830/i830_screen.c4
-rw-r--r--src/mesa/drivers/dri/i830/server/i830_dri.h1
2 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i830/i830_screen.c b/src/mesa/drivers/dri/i830/i830_screen.c
index 4d47f161818..25def0b6fec 100644
--- a/src/mesa/drivers/dri/i830/i830_screen.c
+++ b/src/mesa/drivers/dri/i830/i830_screen.c
@@ -146,6 +146,10 @@ static GLboolean i830InitDriver(__DRIscreenPrivate *sPriv)
(PFNGLXSCRENABLEEXTENSIONPROC) (*dri_interface->getProcAddress("glxEnableExtension"));
void * const psc = sPriv->psc->screenConfigs;
+ if (sPriv->devPrivSize != sizeof(I830DRIRec)) {
+ fprintf(stderr,"\nERROR! sizeof(I830DRIRec) does not match passed size from device driver\n");
+ return GL_FALSE;
+ }
/* Allocate the private area */
i830Screen = (i830ScreenPrivate *)CALLOC(sizeof(i830ScreenPrivate));
diff --git a/src/mesa/drivers/dri/i830/server/i830_dri.h b/src/mesa/drivers/dri/i830/server/i830_dri.h
index 6477f4e79ff..e4b36cc16a2 100644
--- a/src/mesa/drivers/dri/i830/server/i830_dri.h
+++ b/src/mesa/drivers/dri/i830/server/i830_dri.h
@@ -18,7 +18,6 @@
typedef struct _I830DRIRec {
drm_handle_t regs;
drmSize regsSize;
- drmAddress regsMap;
drmSize backbufferSize;
drm_handle_t backbuffer;