diff options
author | Alan Hourihane <[email protected]> | 2005-08-15 06:59:24 +0000 |
---|---|---|
committer | Alan Hourihane <[email protected]> | 2005-08-15 06:59:24 +0000 |
commit | dabec11d277e68b6940e741651e61102767240b9 (patch) | |
tree | 12e8d6988b4b20a0d4fbcf4312ee89f66ddb1225 /src/mesa/drivers/dri/i810 | |
parent | 69dc32cfac945bf664ddfbd6f0116404f893e66e (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/i810')
-rw-r--r-- | src/mesa/drivers/dri/i810/i810screen.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i810/server/i810_dri.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i810/server/i810_dri.h | 1 |
3 files changed, 6 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/i810/i810screen.c b/src/mesa/drivers/dri/i810/i810screen.c index 7c5f38e3586..c6546d1ebd2 100644 --- a/src/mesa/drivers/dri/i810/i810screen.c +++ b/src/mesa/drivers/dri/i810/i810screen.c @@ -223,6 +223,10 @@ i810InitDriver(__DRIscreenPrivate *sPriv) i810ScreenPrivate *i810Screen; I810DRIPtr gDRIPriv = (I810DRIPtr)sPriv->pDevPriv; + if (sPriv->devPrivSize != sizeof(I810DRIRec)) { + fprintf(stderr,"\nERROR! sizeof(I810DRIRec) does not match passed size from device driver\n"); + return GL_FALSE; + } /* Allocate the private area */ i810Screen = (i810ScreenPrivate *)CALLOC(sizeof(i810ScreenPrivate)); diff --git a/src/mesa/drivers/dri/i810/server/i810_dri.c b/src/mesa/drivers/dri/i810/server/i810_dri.c index 17e0f4ead3f..f52797c5ed2 100644 --- a/src/mesa/drivers/dri/i810/server/i810_dri.c +++ b/src/mesa/drivers/dri/i810/server/i810_dri.c @@ -212,7 +212,7 @@ static int I810DRIAgpInit( const DRIDriverContext *ctx, I810Ptr info) drmAgpAlloc(ctx->drmFD, 4096 * 1024, 1, NULL, &dcacheHandle); info->dcacheHandle = dcacheHandle; - fprintf(stderr, "[agp] dcacheHandle : %p\n", dcacheHandle); + fprintf(stderr, "[agp] dcacheHandle : 0x%x\n", dcacheHandle); #define Elements(x) sizeof(x)/sizeof(*x) for (pitch_idx = 0; pitch_idx < Elements(i810_pitches); pitch_idx++) @@ -710,7 +710,7 @@ static int I810ScreenInit( DRIDriverContext *ctx, I810Ptr info ) return 0; } fprintf(stderr, - "[drm] register handle = 0x%08lx\n", info->regs); + "[drm] register handle = 0x%08x\n", info->regs); I810DRIAgpPreInit(ctx, info); /* Need to AddMap the framebuffer and mmio regions here: diff --git a/src/mesa/drivers/dri/i810/server/i810_dri.h b/src/mesa/drivers/dri/i810/server/i810_dri.h index 2e710a414ac..408a4ebb4d5 100644 --- a/src/mesa/drivers/dri/i810/server/i810_dri.h +++ b/src/mesa/drivers/dri/i810/server/i810_dri.h @@ -11,7 +11,6 @@ typedef struct { drm_handle_t regs; drmSize regsSize; - drmAddress regsMap; drmSize backbufferSize; drm_handle_t backbuffer; |