SOURCES: xorg-driver-video-sunffb-nodri.patch (NEW) - disable dri, ...

tommat tommat at pld-linux.org
Thu Jan 3 21:23:15 CET 2008


Author: tommat                       Date: Thu Jan  3 20:23:15 2008 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- disable dri, patch from xorg git

---- Files affected:
SOURCES:
   xorg-driver-video-sunffb-nodri.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SOURCES/xorg-driver-video-sunffb-nodri.patch
diff -u /dev/null SOURCES/xorg-driver-video-sunffb-nodri.patch:1.1
--- /dev/null	Thu Jan  3 21:23:15 2008
+++ SOURCES/xorg-driver-video-sunffb-nodri.patch	Thu Jan  3 21:23:09 2008
@@ -0,0 +1,1117 @@
+From: David S. Miller <davem at davemloft.net>
+Date: Fri, 28 Dec 2007 21:55:06 +0000 (+0200)
+Subject: Remove DRI support to fix build after devPrivates rework
+X-Git-Url: http://gitweb.freedesktop.org/?p=xorg/driver/xf86-video-sunffb.git;a=commitdiff;h=843d93e775cd46a0e24e1a725594fa2d942f14ba
+
+Remove DRI support to fix build after devPrivates rework
+
+This driver uses devprivates of all kinds, but this is
+only done in deprecated and unused code so we can simply
+remove it all.
+
+DRM/DRI support has been commented out for years, and was
+done during the conversion over to XAA acceleration.  This
+code would need to be essentially rewritten to work again,
+so we can just remove this stuff for now.
+
+The rest were either:
+
+1) DRI/DRM related uses
+2) the private allocation code
+3) cases that could index to the pScrn to get the FFB private
+
+And that's all fixed up here.
+
+Signed-off-by: David S. Miller <davem at davemloft.net>
+---
+
+--- a/src/ffb.h
++++ b/src/ffb.h
+@@ -39,10 +39,6 @@
+ #include "ffb_regs.h"
+ #include "xf86sbusBus.h"
+ #include "ffb_dac.h"
+-#ifdef XF86DRI
+-#include "xf86drm.h"
+-#include "ffb_drishare.h"
+-#endif
+ #ifndef  DPMS_SERVER
+ #define  DPMS_SERVER
+ #endif   /* DPMS_SERVER */
+@@ -97,14 +93,6 @@ typedef struct {
+ 	unsigned int bits[32];			/* The stipple bits themselves	*/
+ } CreatorStippleRec, *CreatorStipplePtr;
+ 
+-typedef struct {
+-	int type;
+-	unsigned int linepat;
+-	CreatorStipplePtr stipple;
+-	void (*PolySegment)(DrawablePtr, GCPtr, int, xSegment *);
+-	void (*Polylines)(DrawablePtr, GCPtr, int, int, DDXPointPtr);
+-} CreatorPrivGCRec, *CreatorPrivGCPtr;
+-
+ /* WID and framebuffer controls are a property of the
+  * window.
+  */
+@@ -135,12 +123,6 @@ enum ffb_chip_type {
+ 	afb_m6			/* FCS Elite3D, 6 float chips */
+ };
+ 
+-#ifdef XF86DRI
+-typedef struct {
+-	int	index;
+-} FFBConfigPrivRec, *FFBConfigPrivPtr;
+-#endif
+-
+ typedef struct {
+ 	unsigned short fifo_cache;
+ 	unsigned short rp_active;
+@@ -221,16 +203,6 @@ typedef struct {
+ 	void *I2C;
+ 	struct ffb_dac_info dac_info;
+ 
+-#ifdef XF86DRI
+-	void *pDRIInfo;
+-	int numVisualConfigs;
+-	void *pVisualConfigs;
+-	FFBConfigPrivPtr pVisualConfigsPriv;
+-	int drmSubFD;
+-	Bool dri_enabled;
+-	ffb_dri_state_t *pFfbSarea;
+-#endif
+-
+ 	OptionInfoPtr Options;
+ } FFBRec, *FFBPtr;
+ 
+@@ -261,18 +233,10 @@ extern void FFBWidFree(FFBPtr, unsigned 
+ extern unsigned int FFBWidUnshare(FFBPtr, unsigned int);
+ extern unsigned int FFBWidReshare(FFBPtr, unsigned int);
+ extern void FFBWidChangeBuffer(FFBPtr, unsigned int, int);
+-extern Bool FFBWidIsShared(FFBPtr pFfb, unsigned int wid);
+ 
+ /* Accelerated double-buffering. */
+ extern Bool FFBDbePreInit(ScreenPtr);
+ 
+-#ifdef XF86DRI
+-/* DRI support */
+-extern Bool FFBDRIScreenInit(ScreenPtr);
+-extern Bool FFBDRIFinishScreenInit(ScreenPtr);
+-extern void FFBDRICloseScreen(ScreenPtr);
+-#endif
+-
+ /* The fastfill and pagefill buffer sizes change based upon
+  * the resolution.
+  */
+@@ -290,24 +254,8 @@ extern struct fastfill_parms ffb_fastfil
+ 
+ #define FFB_FFPARMS(__fpriv)	(ffb_fastfill_parms[(__fpriv)->ffb_res])
+ 
+-extern int  CreatorScreenPrivateIndex;
+-extern int  CreatorGCPrivateIndex;
+-extern int  CreatorWindowPrivateIndex;
+-
+ #define GET_FFB_FROM_SCRN(p)	((FFBPtr)((p)->driverPrivate))
+ 
+-#define GET_FFB_FROM_SCREEN(s)						\
+-((FFBPtr)(s)->devPrivates[CreatorScreenPrivateIndex].ptr)
+-
+-#define CreatorGetGCPrivate(g)						\
+-((CreatorPrivGCPtr) (g)->devPrivates [CreatorGCPrivateIndex].ptr)
+-
+-#define CreatorGetWindowPrivate(w)					\
+-((CreatorPrivWinPtr) (w)->devPrivates[CreatorWindowPrivateIndex].ptr)
+-                            
+-#define CreatorSetWindowPrivate(w,p) 					\
+-((w)->devPrivates[CreatorWindowPrivateIndex].ptr = (pointer) p)
+-
+ #undef DEBUG_FFB
+ 
+ #ifdef DEBUG_FFB
+--- a/src/ffb_accel.c
++++ b/src/ffb_accel.c
+@@ -44,11 +44,6 @@
+ #include	"ffb_loops.h"
+ #include	"ffb_regs.h"
+ 
+-int	CreatorScreenPrivateIndex;
+-int	CreatorGCPrivateIndex;
+-int	CreatorWindowPrivateIndex;
+-int	CreatorGeneration;
+-
+ /* Indexed by ffb resolution enum. */
+ struct fastfill_parms ffb_fastfill_parms[] = {
+ 	/* fsmall, psmall,  ffh,  ffw,  pfh,  pfw */
+@@ -61,7 +56,8 @@ struct fastfill_parms ffb_fastfill_parms
+ void
+ CreatorVtChange (ScreenPtr pScreen, int enter)
+ {
+-	FFBPtr pFfb = GET_FFB_FROM_SCREEN (pScreen);
++	ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
++	FFBPtr pFfb = GET_FFB_FROM_SCRN (pScrn);
+ 	ffb_fbcPtr ffb = pFfb->regs;
+ 
+ 	pFfb->rp_active = 1;
+@@ -847,22 +843,6 @@ Bool FFBAccelInit(ScreenPtr pScreen, FFB
+ 	XAAInfoRecPtr infoRec;
+ 	ffb_fbcPtr ffb = pFfb->regs;
+ 
+-	if (serverGeneration != CreatorGeneration) {
+-		CreatorScreenPrivateIndex = AllocateScreenPrivateIndex ();
+-		if (CreatorScreenPrivateIndex == -1)
+-			return FALSE;
+-		CreatorGCPrivateIndex = AllocateGCPrivateIndex ();
+-		CreatorWindowPrivateIndex = AllocateWindowPrivateIndex ();
+-		CreatorGeneration = serverGeneration;
+-	}
+-	
+-	if (!AllocateGCPrivate(pScreen, CreatorGCPrivateIndex, sizeof(CreatorPrivGCRec)))
+-		return FALSE;
+-	if (!AllocateWindowPrivate(pScreen, CreatorWindowPrivateIndex, 0))
+-		return FALSE;
+-
+-	pScreen->devPrivates[CreatorScreenPrivateIndex].ptr = pFfb;
+-
+ 	pFfb->xaa_fbc = (FFB_FBC_WB_A | FFB_FBC_WM_COMBINED | FFB_FBC_RB_A |
+ 			 FFB_FBC_WE_FORCEON |
+ 			 FFB_FBC_SB_BOTH |
+--- a/src/ffb_attr.c
++++ b/src/ffb_attr.c
+@@ -81,180 +81,3 @@ void __FFB_Attr_SFB_VAR(FFBPtr pFfb, uns
+ 	ffb->rop = rop;
+ 	ffb->pmask = pmask;
+ }
+-
+-#define NEED_PPC	0x00000001
+-#define NEED_PMASK	0x00000002
+-#define NEED_ROP	0x00000004
+-#define NEED_DRAWOP	0x00000008
+-#define NEED_FG		0x00000010
+-#define NEED_BG		0x00000020
+-#define NEED_FBC	0x00000040
+-#define NEED_WID	0x00000080
+-
+-void __FFB_Attr_GC(FFBPtr pFfb, GCPtr pGC, WindowPtr pWin, unsigned int ppc, int drawop)
+-{
+-	ffb_fbcPtr ffb = pFfb->regs;
+-	unsigned int rop, need_mask, need_count;
+-
+-	need_mask = need_count = 0;
+-	if ((pFfb->ppc_cache & FFB_PPC_GCMASK) != ppc) {
+-		unsigned int newppc = pFfb->ppc_cache & ~FFB_PPC_GCMASK;
+-
+-		newppc |= (ppc & FFB_PPC_GCMASK);
+-		pFfb->ppc_cache = newppc;
+-		need_mask |= NEED_PPC;
+-		need_count++;
+-	}
+-
+-	if (pFfb->pmask_cache != pGC->planemask) {
+-		pFfb->pmask_cache = pGC->planemask;
+-		need_mask |= NEED_PMASK;
+-		need_count++;
+-	}
+-
+-	rop = (pGC->alu | FFB_ROP_EDIT_BIT)|(FFB_ROP_NEW<<8);
+-	if (pFfb->rop_cache != rop) {
+-		pFfb->rop_cache = rop;
+-		need_mask |= NEED_ROP;
+-		need_count++;
+-	}
+-
+-	if (pFfb->drawop_cache != drawop) {
+-		pFfb->drawop_cache = drawop;
+-		need_mask |= NEED_DRAWOP;
+-		need_count++;
+-	}
+-
+-	if (pFfb->fg_cache != pGC->fgPixel) {
+-		pFfb->fg_cache = pGC->fgPixel;
+-		need_mask |= NEED_FG;
+-		need_count++;
+-	}
+-
+-	{
+-		CreatorPrivWinPtr WinPriv = CreatorGetWindowPrivate(pWin);
+-		unsigned int fbc = WinPriv->fbc_base;
+-
+-		fbc &= ~FFB_FBC_XE_MASK;
+-		fbc |= FFB_FBC_XE_OFF;
+-
+-		if (pFfb->fbc_cache != fbc) {
+-			pFfb->fbc_cache = fbc;
+-			need_mask |= NEED_FBC;
+-			need_count++;
+-		}
+-
+-	}
+-	pFfb->rp_active = 1;
+-
+-	FFBLOG(("WRATTRS_GC: PPC[%08x:%08x] PMSK[%08x] ROP[%08x] "
+-		"DOP[%08x] FG[%08x] FBC[%08x]\n",
+-		pFfb->ppc_cache & FFB_PPC_GCMASK, FFB_PPC_GCMASK,
+-		pFfb->pmask_cache, pFfb->rop_cache,
+-		pFfb->drawop_cache, pFfb->fg_cache, pFfb->fbc_cache));
+-
+-	FFBFifo(pFfb, need_count);
+-	if (need_mask & NEED_PPC)
+-		ffb->ppc = (pFfb->ppc_cache & FFB_PPC_GCMASK);
+-	if (need_mask & NEED_PMASK)
+-		ffb->pmask = pFfb->pmask_cache;
+-	if (need_mask & NEED_ROP)
+-		ffb->rop = pFfb->rop_cache;
+-	if (need_mask & NEED_DRAWOP)
+-		ffb->drawop = pFfb->drawop_cache;
+-	if (need_mask & NEED_FG)
+-		ffb->fg = pFfb->fg_cache;
+-	if (need_mask & NEED_FBC)
+-		ffb->fbc = pFfb->fbc_cache;
+-}
+-
+-void __FFB_Attr_FastfillWin(FFBPtr pFfb, WindowPtr pWin,
+-			    unsigned int ppc, unsigned int pixel)
+-{
+-	ffb_fbcPtr ffb = pFfb->regs;
+-	unsigned int rop, need_mask, need_count;
+-
+-	need_mask = need_count = 0;
+-	if ((pFfb->ppc_cache & FFB_PPC_WINMASK) != ppc) {
+-		unsigned int newppc = pFfb->ppc_cache & ~FFB_PPC_WINMASK;
+-
+-		newppc |= (ppc & FFB_PPC_WINMASK);
+-		pFfb->ppc_cache = newppc;
+-		need_mask |= NEED_PPC;
+-		need_count++;
+-	}
+-
+-	if (pFfb->pmask_cache != 0x00ffffff) {
+-		pFfb->pmask_cache = 0x00ffffff;
+-		need_mask |= NEED_PMASK;
+-		need_count++;
+-	}
+-
+-	rop = FFB_ROP_NEW | (FFB_ROP_NEW<<8);
+-	if (pFfb->rop_cache != rop) {
+-		pFfb->rop_cache = rop;
+-		need_mask |= NEED_ROP;
+-		need_count++;
+-	}
+-
+-	if (pFfb->drawop_cache != FFB_DRAWOP_FASTFILL) {
+-		pFfb->drawop_cache = FFB_DRAWOP_FASTFILL;
+-		need_mask |= NEED_DRAWOP;
+-		need_count++;
+-	}
+-
+-	if (pFfb->fg_cache != pixel) {
+-		pFfb->fg_cache = pixel;
+-		need_mask |= NEED_FG;
+-		need_count++;
+-	}
+-
+-	{
+-		CreatorPrivWinPtr pWinPriv = CreatorGetWindowPrivate(pWin);
+-		unsigned int fbc = pWinPriv->fbc_base;
+-
+-		if (pFfb->has_double_buffer) {
+-			fbc &= ~FFB_FBC_WB_MASK;
+-			fbc |= FFB_FBC_WB_AB;
+-		}
+-		fbc &= ~(FFB_FBC_XE_MASK | FFB_FBC_RGBE_MASK);
+-		fbc |= FFB_FBC_XE_ON | FFB_FBC_RGBE_ON;
+-		if (pFfb->ffb_res == ffb_res_high)
+-			fbc |= FFB_FBC_WB_B;
+-
+-		if (pFfb->fbc_cache != fbc) {
+-			pFfb->fbc_cache = fbc;
+-			need_mask |= NEED_FBC;
+-			need_count++;
+-		}
+-
+-		if (pFfb->wid_cache != pWinPriv->wid) {
+-			pFfb->wid_cache = pWinPriv->wid;
+-			need_mask |= NEED_WID;
+-			need_count++;
+-		}
+-	}
+-
+-	pFfb->rp_active = 1;
+-
+-	FFBLOG(("WRATTRS_GC: PPC[%08x:%08x] PMSK[%08x] ROP[%08x] DOP[%08x] FG[%08x] FBC[%08x] WID[%02x]\n",
+-		pFfb->ppc_cache & FFB_PPC_WINMASK, FFB_PPC_WINMASK,
+-		pFfb->pmask_cache, pFfb->rop_cache,
+-		pFfb->drawop_cache, pFfb->fg_cache, pFfb->fbc_cache, pFfb->wid_cache));
+-
+-	FFBFifo(pFfb, need_count);
+-	if (need_mask & NEED_PPC)
+-		ffb->ppc = (pFfb->ppc_cache & FFB_PPC_WINMASK);
+-	if (need_mask & NEED_PMASK)
+-		ffb->pmask = pFfb->pmask_cache;
+-	if (need_mask & NEED_ROP)
+-		ffb->rop = pFfb->rop_cache;
+-	if (need_mask & NEED_DRAWOP)
+-		ffb->drawop = pFfb->drawop_cache;
+-	if (need_mask & NEED_FG)
+-		ffb->fg = pFfb->fg_cache;
+-	if (need_mask & NEED_FBC)
+-		ffb->fbc = pFfb->fbc_cache;
+-	if (need_mask & NEED_WID)
+-		ffb->wid = pFfb->wid_cache;
+-}
+--- a/src/ffb_dri.c
++++ /dev/null
+@@ -1,521 +0,0 @@
+-/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sunffb/ffb_dri.c,v 1.8 2001/04/18 14:52:42 dawes Exp $
+- * Acceleration for the Creator and Creator3D framebuffer - DRI/DRM support.
+- *
+- * Copyright (C) 2000 David S. Miller (davem at redhat.com)
+- *
+- * 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 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
+- * DAVID MILLER 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.
+- *
+- */
+-
+-#ifdef HAVE_CONFIG_H
+-#include "config.h"
+-#endif
+-
+-#include <stdio.h>
+-
+-#include "xf86.h"
+-#include "xf86_OSproc.h"
+-#include "xf86Priv.h"
+-
+-#include "xf86PciInfo.h"
+-#include "xf86Pci.h"
+-
+-#include "miline.h"
+-
+-#include "GL/glxtokens.h"
+-
+-#include "xf86drm.h"
+-#include "sarea.h"
+-#define _XF86DRI_SERVER_
+-#include "dri.h"
+-
+-#include "GL/glxint.h"
+-
+-#include "ffb.h"
+-#include "ffb_regs.h"
+-#include "ffb_fifo.h"
+-#include "ffb_rcache.h"
+-
+-static char FFBKernelDriverName[] = "ffb";
+-static char FFBClientDriverName[] = "ffb";
+-
+-/* Forward declarations. */
+-static Bool FFBDRICreateContext(ScreenPtr, VisualPtr, drm_context_t,
+-				void *, DRIContextType);
+-static void FFBDRIDestroyContext(ScreenPtr, drm_context_t, DRIContextType);
+-
+-static void FFBDRIInitBuffers(WindowPtr, RegionPtr, CARD32);
+-static void FFBDRIMoveBuffers(WindowPtr, DDXPointRec, RegionPtr, CARD32);
+-
+-static void FFBDRISetDrawableIndex(WindowPtr, CARD32);
+-
+-/* XXX Why isn't this in a header somewhere? XXX */
+-extern void GlxSetVisualConfigs(int nconfigs, __GLXvisualConfig *configs,
+-				void **configprivs);
+-
+-static Bool
+-FFBDRIInitVisualConfigs(ScreenPtr pScreen)
+-{
+-	ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+-	FFBPtr pFfb = GET_FFB_FROM_SCRN(pScrn);
+-	__GLXvisualConfig *pConfigs;
+-	FFBConfigPrivPtr pFfbConfigs;
+-	FFBConfigPrivPtr *pFfbConfigPtrs;
+-
+-	pConfigs = (__GLXvisualConfig *)
+-		xcalloc(sizeof(__GLXvisualConfig), 1);
+-	if (!pConfigs)
+-		return FALSE;
+-
+-	pFfbConfigs = (FFBConfigPrivPtr)
+-		xcalloc(sizeof(FFBConfigPrivRec), 1);
+-	if (!pFfbConfigs) {
+-		xfree(pConfigs);
+-		return FALSE;
+-	}
+-
+-	pFfbConfigPtrs = (FFBConfigPrivPtr *)
+-		xcalloc(sizeof(FFBConfigPrivPtr), 1);
+-	if (!pFfbConfigPtrs) {
+-		xfree(pConfigs);
+-		xfree(pFfbConfigs);
+-		return FALSE;
+-	}
+-
+-	pFfbConfigPtrs[0] = &pFfbConfigs[0];
+-
+-	pConfigs->vid = -1;
+-	pConfigs->class = -1;
+-	pConfigs->rgba = TRUE;
+-	pConfigs->redSize = 8;
+-	pConfigs->greenSize = 8;
+-	pConfigs->blueSize = 8;
+-	pConfigs->alphaSize = 0;
+-	pConfigs->redMask = 0x000000ff;
+-	pConfigs->greenMask = 0x0000ff00;
+-	pConfigs->blueMask = 0x00ff0000;
+-	pConfigs->alphaMask = 0;
+-	pConfigs->accumRedSize = 0;
+-	pConfigs->accumGreenSize = 0;
+-	pConfigs->accumBlueSize = 0;
+-	pConfigs->accumAlphaSize = 0;
+-	pConfigs->doubleBuffer = TRUE;
+-	pConfigs->stereo = FALSE;
+-	pConfigs->bufferSize = 32;
+-	pConfigs->depthSize = 16;
+-	pConfigs->stencilSize = 0;
+-	pConfigs->auxBuffers = 0;
+-	pConfigs->level = 0;
+-	pConfigs->visualRating = GLX_NONE;
+-	pConfigs->transparentPixel = GLX_NONE;
+-	pConfigs->transparentRed = 0;
+-	pConfigs->transparentGreen = 0;
+-	pConfigs->transparentBlue = 0;
+-	pConfigs->transparentAlpha = 0;
+-	pConfigs->transparentIndex = 0;
+-
+-	pFfb->numVisualConfigs = 1;
+-	pFfb->pVisualConfigs = pConfigs;
+-	pFfb->pVisualConfigsPriv = pFfbConfigs;
+-
+-	GlxSetVisualConfigs(1, pConfigs, (void **)pFfbConfigPtrs);
+-
+-	return TRUE;
+-}
+-
+-static void
+-init_ffb_sarea(FFBPtr pFfb, ffb_dri_state_t *pFfbSarea)
+-{
+-	int i;
+-
+-	pFfbSarea->flags = 0;
+-
+-	switch (pFfb->ffb_type) {
+-	case ffb2_prototype:
+-	case ffb2_vertical:
+-	case ffb2_vertical_plus:
+-	case ffb2_horizontal:
+-	case ffb2_horizontal_plus:
+-		pFfbSarea->flags |= FFB_DRI_FFB2;
+-		break;
+-
+-	default:
+-		break;
+-	};
+-
+-	if (pFfb->ffb_type == ffb2_vertical_plus ||
+-	    pFfb->ffb_type == ffb2_horizontal_plus)
+-		pFfbSarea->flags |= FFB_DRI_FFB2PLUS;
+-
+-	if (pFfb->dac_info.flags & FFB_DAC_PAC1)
+-		pFfbSarea->flags |= FFB_DRI_PAC1;
+-
+-	if (pFfb->dac_info.flags & FFB_DAC_PAC2)
+-		pFfbSarea->flags |= FFB_DRI_PAC2;
+-
+-	for (i = 0; i < FFB_DRI_NWIDS; i++)
+-		pFfbSarea->wid_table[i] = 0;
+-}
+-
+-#define	FFB_DFB24_POFF		0x02000000UL
+-#define	FFB_DFB24_SIZE		0x01000000UL
+-
+-#define	FFB_FBC_REGS_POFF	0x00600000UL
+-#define	FFB_FBC_REGS_SIZE	0x00002000UL
+-
+-#define	FFB_DAC_POFF		0x00400000UL
+-#define	FFB_DAC_SIZE		0x00002000UL
+-
+-#define	FFB_SFB8R_POFF		0x04000000UL
+-#define FFB_SFB8R_SIZE		0x00400000UL
+-
+-#define	FFB_SFB32_POFF		0x05000000UL
+-#define FFB_SFB32_SIZE		0x01000000UL
+-
+-#define	FFB_SFB64_POFF		0x06000000UL
+-#define FFB_SFB64_SIZE		0x02000000UL
+-
+-Bool
+-FFBDRIScreenInit(ScreenPtr pScreen)
+-{
+-	ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+-	FFBPtr pFfb = GET_FFB_FROM_SCRN(pScrn);
+-	DRIInfoPtr pDRIInfo;
+-	FFBDRIPtr pFfbDRI;
+-
+-	/* Check that the GLX, DRI, and DRM modules have been loaded by testing
+-	 * for canonical symbols in each module.
+-	 */
+-	if (!xf86LoaderCheckSymbol("GlxSetVisualConfigs"))
+-		return FALSE;
+-	if (!xf86LoaderCheckSymbol("drmAvailable"))
+-		return FALSE;
+-        if (!xf86LoaderCheckSymbol("DRIQueryVersion")) {
+-      		xf86DrvMsg(pScreen->myNum, X_ERROR,
+-                 	"FFBDRIScreenInit failed (libdri.a too old)\n");
+-		return FALSE;
+-        }
+-
+-        /* Check the DRI version */
+-        {
+-      		int major, minor, patch;
+-		DRIQueryVersion(&major, &minor, &patch);
+-		if (major != DRIINFO_MAJOR_VERSION || minor < DRIINFO_MINOR_VERSION) {
+-		xf86DrvMsg(pScreen->myNum, X_ERROR,
+-                    "[dri] FFBDRIScreenInit failed because of a version mismatch.\n"
+-		    "[dri] libdri version is %d.%d.%d but version %d.%d.x is needed.\n"
+-		    "[dri]  Disabling DRI.\n",
+-                    major, minor, patch,
+-                    DRIINFO_MAJOR_VERSION, DRIINFO_MINOR_VERSION);
+-		return FALSE;
+-		}
+-	}
+-
+-	pDRIInfo = DRICreateInfoRec();
<<Diff was trimmed, longer than 597 lines>>


More information about the pld-cvs-commit mailing list