diff options
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/common/dri_util.c | 8 | ||||
-rw-r--r-- | src/mesa/drivers/dri/common/dri_util.h | 6 | ||||
-rw-r--r-- | src/mesa/drivers/dri/dri_client/imports/sarea.h | 94 | ||||
-rw-r--r-- | src/mesa/drivers/dri/ffb/ffb_context.h | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/ffb/ffb_tex.c | 1 | ||||
-rw-r--r-- | src/mesa/drivers/dri/mach64/mach64_texmem.c | 8 | ||||
-rw-r--r-- | src/mesa/drivers/dri/mach64/server/mach64_common.h | 131 | ||||
-rw-r--r-- | src/mesa/drivers/dri/mach64/server/mach64_sarea.h | 160 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r128/server/r128_dri.h | 1 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r200/r200_tex.c | 4 | ||||
-rw-r--r-- | src/mesa/drivers/dri/sis/server/sis_dri.h | 1 | ||||
-rw-r--r-- | src/mesa/drivers/dri/tdfx/server/tdfx_dri.h | 1 |
12 files changed, 18 insertions, 399 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 05bfce8f532..f60c772c784 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -40,7 +40,7 @@ #ifndef DRI_NEW_INTERFACE_ONLY # include "xf86dri.h" #endif /* DRI_NEW_INTERFACE_ONLY */ -#include "sarea.h" +#include "drm_sarea.h" #include "glcontextmodes.h" #ifndef GLX_OML_sync_control @@ -316,7 +316,7 @@ static void __driGarbageCollectDrawables(void *drawHash) * While casting the opaque private pointers associated with the parameters * into their respective real types it also assures they are not \c NULL. */ -static Bool driUnbindContext3(__DRInativeDisplay *dpy, int scrn, +static GLboolean driUnbindContext3(__DRInativeDisplay *dpy, int scrn, __DRIid draw, __DRIid read, __DRIcontext *ctx) { @@ -498,7 +498,7 @@ static Bool DoBindContext(__DRInativeDisplay *dpy, * for \c glXMakeCurrentReadSGI or GLX 1.3's \c glXMakeContextCurrent * function. */ -static Bool driBindContext3(__DRInativeDisplay *dpy, int scrn, +static GLboolean driBindContext3(__DRInativeDisplay *dpy, int scrn, __DRIid draw, __DRIid read, __DRIcontext * ctx) { @@ -1167,7 +1167,7 @@ __driUtilCreateNewScreen(__DRInativeDisplay *dpy, int scrn, __DRIscreen *psc, const __DRIversion * dri_version, const __DRIversion * drm_version, const __DRIframebuffer * frame_buffer, - drmAddress pSAREA, + drm_sarea_t *pSAREA, int fd, int internal_api_version, const struct __DriverAPIRec *driverAPI) diff --git a/src/mesa/drivers/dri/common/dri_util.h b/src/mesa/drivers/dri/common/dri_util.h index 7db67513019..cd338efd791 100644 --- a/src/mesa/drivers/dri/common/dri_util.h +++ b/src/mesa/drivers/dri/common/dri_util.h @@ -56,7 +56,7 @@ #include <inttypes.h> #include "glxclient.h" /* for GLXDrawable */ #include "drm.h" /* for drm_clip_rect_t */ -#include "sarea.h" /* for XF86DRISAREAPtr */ +#include "drm_sarea.h" /* for XF86DRISAREAPtr */ #include "GL/internal/glcore.h" /* for __GLcontextModes */ /* This is a temporary relic. Once all drivers are converted to support @@ -481,7 +481,7 @@ struct __DRIscreenPrivateRec { * - the device lock * - the device-independent per-drawable and per-context(?) information */ - XF86DRISAREAPtr pSAREA; + drm_sarea_t *pSAREA; /** * \name Direct frame buffer access information @@ -563,7 +563,7 @@ extern __DRIscreenPrivate * __driUtilCreateNewScreen( __DRInativeDisplay *dpy, int scrn, __DRIscreen *psc, __GLcontextModes * modes, const __DRIversion * ddx_version, const __DRIversion * dri_version, const __DRIversion * drm_version, const __DRIframebuffer * frame_buffer, - drmAddress pSAREA, int fd, int internal_api_version, + drm_sarea_t *pSAREA, int fd, int internal_api_version, const struct __DriverAPIRec *driverAPI ); #ifndef DRI_NEW_INTERFACE_ONLY diff --git a/src/mesa/drivers/dri/dri_client/imports/sarea.h b/src/mesa/drivers/dri/dri_client/imports/sarea.h deleted file mode 100644 index 77c16e0efe2..00000000000 --- a/src/mesa/drivers/dri/dri_client/imports/sarea.h +++ /dev/null @@ -1,94 +0,0 @@ -/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */ -/** - * \file sarea.h - * SAREA definitions. - * - * \author Kevin E. Martin <kevin@precisioninsight.com> - * \author Jens Owen <jens@tungstengraphics.com> - * \author Rickard E. (Rik) Faith <faith@valinux.com> - */ - -/* - * Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas. - * Copyright 2000 VA Linux Systems, Inc. - * All Rights Reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the - * "Software"), to deal in the Software without restriction, including - * without limitation the rights to use, copy, modify, merge, publish, - * distribute, sub license, and/or sell copies of the Software, and to - * permit persons to whom the Software is furnished to do so, subject to - * the following conditions: - * - * The above copyright notice and this permission notice (including the - * next paragraph) shall be included in all copies or substantial portions - * of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS - * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF - * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. - * IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR - * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, - * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE - * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - */ - -/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */ - -#ifndef _SAREA_H_ -#define _SAREA_H_ - -#include "xf86drm.h" - -/* SAREA area needs to be at least a page */ -#if defined(__alpha__) -#define SAREA_MAX 0x2000 -#elif defined(__ia64__) -#define SAREA_MAX 0x10000 /* 64kB */ -#else -/* Intel 830M driver needs at least 8k SAREA */ -#define SAREA_MAX 0x2000 -#endif - -#define SAREA_MAX_DRAWABLES 256 - -#define SAREA_DRAWABLE_CLAIMED_ENTRY 0x80000000 - -/** - * SAREA per drawable information. - * - * \sa _XF86DRISAREA. - */ -typedef struct _XF86DRISAREADrawable { - unsigned int stamp; - unsigned int flags; -} XF86DRISAREADrawableRec, *XF86DRISAREADrawablePtr; - -/** - * SAREA frame information. - * - * \sa _XF86DRISAREA. - */ -typedef struct _XF86DRISAREAFrame { - unsigned int x; - unsigned int y; - unsigned int width; - unsigned int height; - unsigned int fullscreen; -} XF86DRISAREAFrameRec, *XF86DRISAREAFramePtr; - -/** - * SAREA definition. - */ -typedef struct _XF86DRISAREA { - /** first thing is always the DRM locking structure */ - drmLock lock; - /** \todo Use readers/writer lock for drawable_lock */ - drmLock drawable_lock; - XF86DRISAREADrawableRec drawableTable[SAREA_MAX_DRAWABLES]; - XF86DRISAREAFrameRec frame; - drm_context_t dummy_context; -} XF86DRISAREARec, *XF86DRISAREAPtr; - -#endif diff --git a/src/mesa/drivers/dri/ffb/ffb_context.h b/src/mesa/drivers/dri/ffb/ffb_context.h index 80fb221e3e3..33f6f7cff80 100644 --- a/src/mesa/drivers/dri/ffb/ffb_context.h +++ b/src/mesa/drivers/dri/ffb/ffb_context.h @@ -263,7 +263,7 @@ do { if ((STATE_MASK) & ~((FMESA)->state_dirty)) { \ float Znear, Zfar; drm_context_t hHWContext; - drmLock *driHwLock; + drm_hw_lock_t *driHwLock; int driFd; unsigned int clear_pixel; diff --git a/src/mesa/drivers/dri/ffb/ffb_tex.c b/src/mesa/drivers/dri/ffb/ffb_tex.c index 24d7fe3cd2c..d6763b7cd3e 100644 --- a/src/mesa/drivers/dri/ffb/ffb_tex.c +++ b/src/mesa/drivers/dri/ffb/ffb_tex.c @@ -27,6 +27,7 @@ #include "glheader.h" #include "mtypes.h" +#include "ffb_tex.h" /* No texture unit, all software. */ /* XXX this function isn't needed since _mesa_init_driver_functions() diff --git a/src/mesa/drivers/dri/mach64/mach64_texmem.c b/src/mesa/drivers/dri/mach64/mach64_texmem.c index 2951fa706f1..f771818c898 100644 --- a/src/mesa/drivers/dri/mach64/mach64_texmem.c +++ b/src/mesa/drivers/dri/mach64/mach64_texmem.c @@ -28,7 +28,7 @@ * Authors: * Gareth Hughes <gareth@valinux.com> * Leif Delgass <ldelgass@retinalburn.net> - * Jos� Fonseca <j_r_fonseca@yahoo.co.uk> + * Jose Fonseca <j_r_fonseca@yahoo.co.uk> */ #include "mach64_context.h" @@ -174,7 +174,7 @@ void mach64PrintLocalLRU( mach64ContextPtr mmesa, int heap ) void mach64PrintGlobalLRU( mach64ContextPtr mmesa, int heap ) { - drmTextureRegion *list = mmesa->sarea->tex_list[heap]; + drm_tex_region_t *list = mmesa->sarea->tex_list[heap]; int i, j; fprintf( stderr, "\nGlobal LRU, heap %d list %p:\n", heap, list ); @@ -202,7 +202,7 @@ void mach64PrintGlobalLRU( mach64ContextPtr mmesa, int heap ) /* NOTE: This function is only called while holding the hardware lock */ static void mach64ResetGlobalLRU( mach64ContextPtr mmesa, int heap ) { - drmTextureRegion *list = mmesa->sarea->tex_list[heap]; + drm_tex_region_t *list = mmesa->sarea->tex_list[heap]; int sz = 1 << mmesa->mach64Screen->logTexGranularity[heap]; int i; @@ -234,7 +234,7 @@ void mach64UpdateTexLRU( mach64ContextPtr mmesa, mach64TexObjPtr t ) { int heap = t->heap; - drmTextureRegion *list = mmesa->sarea->tex_list[heap]; + drm_tex_region_t *list = mmesa->sarea->tex_list[heap]; int log2sz = mmesa->mach64Screen->logTexGranularity[heap]; int start = t->memBlock->ofs >> log2sz; int end = (t->memBlock->ofs + t->memBlock->size - 1) >> log2sz; diff --git a/src/mesa/drivers/dri/mach64/server/mach64_common.h b/src/mesa/drivers/dri/mach64/server/mach64_common.h deleted file mode 100644 index 00609e31a4b..00000000000 --- a/src/mesa/drivers/dri/mach64/server/mach64_common.h +++ /dev/null @@ -1,131 +0,0 @@ -/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */ -/* mach64_common.h -- common header definitions for Rage Pro 2D/3D/DRM suite - * Created: Sun Dec 03 11:34:16 2000 by gareth@valinux.com - * - * Copyright 2000 Gareth Hughes - * All Rights Reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * GARETH HUGHES BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER - * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN - * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - * - * Author: - * Gareth Hughes <gareth@valinux.com> - * Leif Delgass <ldelgass@retinalburn.net> - */ - -#ifndef __MACH64_COMMON_H__ -#define __MACH64_COMMON_H__ 1 - -/* WARNING: If you change any of these defines, make sure to change - * the kernel include file as well (mach64_drm.h) - */ - -/* Driver specific DRM command indices - * NOTE: these are not OS specific, but they are driver specific - */ -#define DRM_MACH64_INIT 0x00 -#define DRM_MACH64_IDLE 0x01 -#define DRM_MACH64_RESET 0x02 -#define DRM_MACH64_SWAP 0x03 -#define DRM_MACH64_CLEAR 0x04 -#define DRM_MACH64_VERTEX 0x05 -#define DRM_MACH64_BLIT 0x06 -#define DRM_MACH64_FLUSH 0x07 -#define DRM_MACH64_GETPARAM 0x08 - -/* Buffer flags for clears - */ -#define MACH64_FRONT 0x1 -#define MACH64_BACK 0x2 -#define MACH64_DEPTH 0x4 - -/* Primitive types for vertex buffers - */ -#define MACH64_PRIM_POINTS 0x00000000 -#define MACH64_PRIM_LINES 0x00000001 -#define MACH64_PRIM_LINE_LOOP 0x00000002 -#define MACH64_PRIM_LINE_STRIP 0x00000003 -#define MACH64_PRIM_TRIANGLES 0x00000004 -#define MACH64_PRIM_TRIANGLE_STRIP 0x00000005 -#define MACH64_PRIM_TRIANGLE_FAN 0x00000006 -#define MACH64_PRIM_QUADS 0x00000007 -#define MACH64_PRIM_QUAD_STRIP 0x00000008 -#define MACH64_PRIM_POLYGON 0x00000009 - - -typedef enum _drmMach64DMAMode { - MACH64_MODE_DMA_ASYNC, - MACH64_MODE_DMA_SYNC, - MACH64_MODE_MMIO -} drmMach64DMAMode; - -typedef struct { - enum { - DRM_MACH64_INIT_DMA = 0x01, - DRM_MACH64_CLEANUP_DMA = 0x02 - } func; - unsigned long sarea_priv_offset; - int is_pci; - drmMach64DMAMode dma_mode; - - unsigned int fb_bpp; - unsigned int front_offset, front_pitch; - unsigned int back_offset, back_pitch; - - unsigned int depth_bpp; - unsigned int depth_offset, depth_pitch; - - unsigned long fb_offset; - unsigned long mmio_offset; - unsigned long ring_offset; - unsigned long buffers_offset; - unsigned long agp_textures_offset; -} drmMach64Init; - -typedef struct { - unsigned int flags; - int x, y, w, h; - unsigned int clear_color; - unsigned int clear_depth; -} drmMach64Clear; - -typedef struct { - int prim; - void *buf; /* Address of vertex buffer */ - unsigned long used; /* Number of bytes in buffer */ - int discard; /* Client finished with buffer? */ -} drmMach64Vertex; - -typedef struct { - int idx; - int pitch; - int offset; - int format; - unsigned short x, y; - unsigned short width, height; -} drmMach64Blit; - -typedef struct { - int param; - int *value; -} drmMach64GetParam; - -#define MACH64_PARAM_FRAMES_QUEUED 1 -#define MACH64_PARAM_IRQ_NR 2 - -#endif /* __MACH64_COMMON_H__ */ diff --git a/src/mesa/drivers/dri/mach64/server/mach64_sarea.h b/src/mesa/drivers/dri/mach64/server/mach64_sarea.h deleted file mode 100644 index a519cde18ad..00000000000 --- a/src/mesa/drivers/dri/mach64/server/mach64_sarea.h +++ /dev/null @@ -1,160 +0,0 @@ -/* $XFree86$ */ /* -*- mode: c; c-basic-offset: 3 -*- */ -/* - * Copyright 2000 Gareth Hughes - * All Rights Reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * GARETH HUGHES BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER - * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN - * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - */ - -/* - * Authors: - * Gareth Hughes <gareth@valinux.com> - * Leif Delgass <ldelgass@retinalburn.net> - */ - -#ifndef __MACH64_SAREA_H__ -#define __MACH64_SAREA_H__ 1 - -/* WARNING: If you change any of these defines, make sure to change the - * defines in the kernel file (mach64_drm.h) - */ -#ifndef __MACH64_SAREA_DEFINES__ -#define __MACH64_SAREA_DEFINES__ 1 - -/* What needs to be changed for the current vertex buffer? - * GH: We're going to be pedantic about this. We want the card to do as - * little as possible, so let's avoid having it fetch a whole bunch of - * register values that don't change all that often, if at all. - */ -#define MACH64_UPLOAD_DST_OFF_PITCH 0x0001 -#define MACH64_UPLOAD_Z_OFF_PITCH 0x0002 -#define MACH64_UPLOAD_Z_ALPHA_CNTL 0x0004 -#define MACH64_UPLOAD_SCALE_3D_CNTL 0x0008 -#define MACH64_UPLOAD_DP_FOG_CLR 0x0010 -#define MACH64_UPLOAD_DP_WRITE_MASK 0x0020 -#define MACH64_UPLOAD_DP_PIX_WIDTH 0x0040 -#define MACH64_UPLOAD_SETUP_CNTL 0x0080 -#define MACH64_UPLOAD_MISC 0x0100 -#define MACH64_UPLOAD_TEXTURE 0x0200 -#define MACH64_UPLOAD_TEX0IMAGE 0x0400 -#define MACH64_UPLOAD_TEX1IMAGE 0x0800 -#define MACH64_UPLOAD_CLIPRECTS 0x1000 /* handled client-side */ -#define MACH64_UPLOAD_CONTEXT 0x00ff -#define MACH64_UPLOAD_ALL 0x1fff - -/* DMA buffer size - */ -#define MACH64_BUFFER_SIZE 16384 - -/* Max number of swaps allowed on the ring - * before the client must wait - */ -#define MACH64_MAX_QUEUED_FRAMES 3 - -/* Byte offsets for host blit buffer data - */ -#define MACH64_HOSTDATA_BLIT_OFFSET 104 - -/* Keep these small for testing. - */ -#define MACH64_NR_SAREA_CLIPRECTS 8 - - -#define MACH64_CARD_HEAP 0 -#define MACH64_AGP_HEAP 1 -#define MACH64_NR_TEX_HEAPS 2 -#define MACH64_NR_TEX_REGIONS 64 -#define MACH64_LOG_TEX_GRANULARITY 16 - -#define MACH64_TEX_MAXLEVELS 1 - -#define MACH64_NR_CONTEXT_REGS 15 -#define MACH64_NR_TEXTURE_REGS 4 - -#endif /* __MACH64_SAREA_DEFINES__ */ - -typedef struct { - /* Context state */ - unsigned int dst_off_pitch; /* 0x500 */ - - unsigned int z_off_pitch; /* 0x548 */ /* ****** */ - unsigned int z_cntl; /* 0x54c */ - unsigned int alpha_tst_cntl; /* 0x550 */ - - unsigned int scale_3d_cntl; /* 0x5fc */ - - unsigned int sc_left_right; /* 0x6a8 */ - unsigned int sc_top_bottom; /* 0x6b4 */ - - unsigned int dp_fog_clr; /* 0x6c4 */ - unsigned int dp_write_mask; /* 0x6c8 */ - unsigned int dp_pix_width; /* 0x6d0 */ - unsigned int dp_mix; /* 0x6d4 */ /* ****** */ - unsigned int dp_src; /* 0x6d8 */ /* ****** */ - - unsigned int clr_cmp_cntl; /* 0x708 */ /* ****** */ - unsigned int gui_traj_cntl; /* 0x730 */ /* ****** */ - - unsigned int setup_cntl; /* 0x304 */ - - /* Texture state */ - unsigned int tex_size_pitch; /* 0x770 */ - unsigned int tex_cntl; /* 0x774 */ - unsigned int secondary_tex_off; /* 0x778 */ - unsigned int tex_offset; /* 0x5c0 */ -} mach64_context_regs_t; - -typedef struct { - /* The channel for communication of state information to the kernel - * on firing a vertex buffer. - */ - mach64_context_regs_t ContextState; - unsigned int dirty; - unsigned int vertsize; - - /* The current cliprects, or a subset thereof. - */ - drm_clip_rect_t boxes[MACH64_NR_SAREA_CLIPRECTS]; - unsigned int nbox; - - /* Counter for throttling of rendering clients. - */ - unsigned int frames_queued; - - /* Maintain an LRU of contiguous regions of texture space. If you - * think you own a region of texture memory, and it has an age - * different to the one you set, then you are mistaken and it has - * been stolen by another client. If global texAge hasn't changed, - * there is no need to walk the list. - * - * These regions can be used as a proxy for the fine-grained texture - * information of other clients - by maintaining them in the same - * lru which is used to age their own textures, clients have an - * approximate lru for the whole of global texture space, and can - * make informed decisions as to which areas to kick out. There is - * no need to choose whether to kick out your own texture or someone - * else's - simply eject them all in LRU order. - */ - drmTextureRegion texList[MACH64_NR_TEX_HEAPS][MACH64_NR_TEX_REGIONS+1]; - unsigned int texAge[MACH64_NR_TEX_HEAPS]; - - int ctxOwner; /* last context to upload state */ -} ATISAREAPrivRec, *ATISAREAPrivPtr; - -#endif /* __MACH64_SAREA_H__ */ diff --git a/src/mesa/drivers/dri/r128/server/r128_dri.h b/src/mesa/drivers/dri/r128/server/r128_dri.h index 4b6e77ecb86..67ade70de47 100644 --- a/src/mesa/drivers/dri/r128/server/r128_dri.h +++ b/src/mesa/drivers/dri/r128/server/r128_dri.h @@ -40,6 +40,7 @@ #define _R128_DRI_ #include "xf86drm.h" +#include "drm.h" /* DRI Driver defaults */ #define R128_DEFAULT_CCE_PIO_MODE R128_PM4_64PIO_64VCBM_64INDBM diff --git a/src/mesa/drivers/dri/r200/r200_tex.c b/src/mesa/drivers/dri/r200/r200_tex.c index e778e75b49b..810607c3538 100644 --- a/src/mesa/drivers/dri/r200/r200_tex.c +++ b/src/mesa/drivers/dri/r200/r200_tex.c @@ -728,7 +728,7 @@ static void r200TexImage3D( GLcontext *ctx, GLenum target, GLint level, driSwapOutTextureObject( t ); } else { - t = r200AllocTexObj( texObj ); + t = (driTextureObject *) r200AllocTexObj( texObj ); if (!t) { _mesa_error(ctx, GL_OUT_OF_MEMORY, "glTexImage3D"); return; @@ -789,7 +789,7 @@ r200TexSubImage3D( GLcontext *ctx, GLenum target, GLint level, driSwapOutTextureObject( t ); } else { - t = r200AllocTexObj(texObj); + t = (driTextureObject *) r200AllocTexObj( texObj ); if (!t) { _mesa_error(ctx, GL_OUT_OF_MEMORY, "glTexSubImage3D"); return; diff --git a/src/mesa/drivers/dri/sis/server/sis_dri.h b/src/mesa/drivers/dri/sis/server/sis_dri.h index ce7c9a3114c..df18ff0bacc 100644 --- a/src/mesa/drivers/dri/sis/server/sis_dri.h +++ b/src/mesa/drivers/dri/sis/server/sis_dri.h @@ -6,6 +6,7 @@ #define _SIS_DRI_ #include "xf86drm.h" +#include "drm.h" #define SIS_MAX_DRAWABLES 256 #define SISIOMAPSIZE (64*1024) diff --git a/src/mesa/drivers/dri/tdfx/server/tdfx_dri.h b/src/mesa/drivers/dri/tdfx/server/tdfx_dri.h index e7ad87d1b1b..8f3104f3d97 100644 --- a/src/mesa/drivers/dri/tdfx/server/tdfx_dri.h +++ b/src/mesa/drivers/dri/tdfx/server/tdfx_dri.h @@ -4,6 +4,7 @@ #define _TDFX_DRI_ #include "xf86drm.h" +#include "drm.h" typedef struct { drm_handle_t regs; |