xf86-video-intel: 5 commits - man/intel.man src/i810_driver.c src/i830_accel.c src/i830_batchbuffer.c src/i830_debug.c src/i830_display.c src/i830_dri.c src/i830_driver.c src/i830.h src/i830_memory.c src/i830_render.c src/i830_ring.h src/i830_video.c src/i830_xaa.c src/i915_render.c src/i915_video.c src/i965_render.c src/i965_video.c

Eric Anholt anholt at kemper.freedesktop.org
Fri Mar 6 13:31:10 PST 2009


 man/intel.man          |    9 -
 src/i810_driver.c      |   67 ----------
 src/i830.h             |   28 ----
 src/i830_accel.c       |    4 
 src/i830_batchbuffer.c |    2 
 src/i830_debug.c       |   10 -
 src/i830_display.c     |    5 
 src/i830_dri.c         |    8 -
 src/i830_driver.c      |  300 +++++++++----------------------------------------
 src/i830_memory.c      |   73 ++---------
 src/i830_render.c      |    2 
 src/i830_ring.h        |   14 +-
 src/i830_video.c       |   59 +--------
 src/i830_xaa.c         |   69 +----------
 src/i915_render.c      |    2 
 src/i915_video.c       |    2 
 src/i965_render.c      |    2 
 src/i965_video.c       |    2 
 18 files changed, 116 insertions(+), 542 deletions(-)

New commits:
commit d2af21a66d7e1d1dd62c6aa8fb41d3fd6045bcd7
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 27 23:38:00 2009 -0800

    Remove configurable support for disabling XV.
    
    google shows one instance of this being used a year and a half ago.

diff --git a/man/intel.man b/man/intel.man
index a8bf579..b5f8791 100644
--- a/man/intel.man
+++ b/man/intel.man
@@ -125,10 +125,6 @@ This is the same as the
 option described above.  It is provided for compatibility with most
 other drivers.
 .TP
-.BI "Option \*qXVideo\*q \*q" boolean \*q
-Disable or enable XVideo support.
-Default: XVideo is enabled for configurations where it is supported.
-.TP
 .BI "Option \*qXvPreferOverlay\*q \*q" boolean \*q
 Make hardware overlay be the first XV adaptor.
 The overlay behaves incorrectly in the presence of compositing, but some prefer
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 60a0076..16f68dc 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -304,7 +304,6 @@ typedef enum {
    OPTION_NOACCEL,
    OPTION_CACHE_LINES,
    OPTION_DRI,
-   OPTION_XVIDEO,
    OPTION_VIDEO_KEY,
    OPTION_COLOR_KEY,
    OPTION_MODEDEBUG,
@@ -326,7 +325,6 @@ static OptionInfoRec I830Options[] = {
    {OPTION_NOACCEL,	"NoAccel",	OPTV_BOOLEAN,	{0},	FALSE},
    {OPTION_CACHE_LINES,	"CacheLines",	OPTV_INTEGER,	{0},	FALSE},
    {OPTION_DRI,		"DRI",		OPTV_BOOLEAN,	{0},	TRUE},
-   {OPTION_XVIDEO,	"XVideo",	OPTV_BOOLEAN,	{0},	TRUE},
    {OPTION_COLOR_KEY,	"ColorKey",	OPTV_INTEGER,	{0},	FALSE},
    {OPTION_VIDEO_KEY,	"VideoKey",	OPTV_INTEGER,	{0},	FALSE},
    {OPTION_MODEDEBUG,	"ModeDebug",	OPTV_BOOLEAN,	{0},	FALSE},
@@ -1763,9 +1761,6 @@ I830XvInit(ScrnInfoPtr pScrn)
     I830Ptr pI830 = I830PTR(pScrn);
     MessageType from = X_PROBED;
 
-    pI830->XvDisabled =
-	!xf86ReturnOptValBool(pI830->Options, OPTION_XVIDEO, TRUE);
-
    pI830->XvPreferOverlay = xf86ReturnOptValBool(pI830->Options, OPTION_PREFER_OVERLAY, FALSE);
 
 #ifdef I830_XV
@@ -3076,7 +3071,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
      * Set this so that the overlay allocation is factored in when
      * appropriate.
      */
-    pI830->XvEnabled = !pI830->XvDisabled;
+    pI830->XvEnabled = TRUE;
 #endif
 
 
@@ -3105,13 +3100,10 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
       return FALSE;
 
 #ifdef I830_XV
-   pI830->XvEnabled = !pI830->XvDisabled;
-   if (pI830->XvEnabled) {
-      if (pI830->accel == ACCEL_NONE) {
-	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Xv is disabled because it "
-		    "needs 2D acceleration.\n");
-	 pI830->XvEnabled = FALSE;
-      }
+   if (pI830->accel == ACCEL_NONE) {
+      xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Xv is disabled because it "
+		 "needs 2D acceleration.\n");
+      pI830->XvEnabled = FALSE;
    }
 #else
    pI830->XvEnabled = FALSE;
@@ -3126,16 +3118,6 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
       }
    }
 
-#ifdef I830_XV
-   if (pI830->XvEnabled) {
-      if (pI830->accel == ACCEL_NONE) {
-	 xf86DrvMsg(pScrn->scrnIndex, X_WARNING, "Disabling Xv because it "
-		    "needs 2D acceleration.\n");
-	 pI830->XvEnabled = FALSE;
-      }
-   }
-#endif
-
    if (!pI830->use_drm_mode) {
       DPRINTF(PFX, "assert( if(!I830MapMem(pScrn)) )\n");
       if (!I830MapMem(pScrn))
commit 755757669f0cad670cfa084d33d7c3e928d27855
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 27 22:57:15 2009 -0800

    Remove configured SW cursor support.
    
    Any time we actually need SW cursors, it gets enabled automatically.

diff --git a/man/intel.man b/man/intel.man
index 01f1505..a8bf579 100644
--- a/man/intel.man
+++ b/man/intel.man
@@ -59,11 +59,6 @@ are supported
 .BI "Option \*qNoAccel\*q \*q" boolean \*q
 Disable or enable acceleration.  Default: acceleration is enabled.
 .TP
-.BI "Option \*qSWCursor\*q \*q" boolean \*q
-Disable or enable software cursor.  Default: software cursor is disable
-and a hardware cursor is used for configurations where the hardware cursor
-is available.
-.TP
 .BI "Option \*qColorKey\*q \*q" integer \*q
 This sets the default pixel value for the YUV video overlay key.
 Default: undefined.
diff --git a/src/i830.h b/src/i830.h
index ffb2732..2408ea9 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -497,7 +497,6 @@ typedef struct _I830Rec {
    Bool fence_used[FENCE_NEW_NR];
 
    accel_method_t accel;
-   Bool SWCursor;
 #ifdef I830_USE_XAA
    XAAInfoRecPtr AccelInfoRec;
 
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 908614a..60a0076 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -302,7 +302,6 @@ static PciChipsets I830PciChipsets[] = {
 typedef enum {
    OPTION_ACCELMETHOD,
    OPTION_NOACCEL,
-   OPTION_SW_CURSOR,
    OPTION_CACHE_LINES,
    OPTION_DRI,
    OPTION_XVIDEO,
@@ -325,7 +324,6 @@ typedef enum {
 static OptionInfoRec I830Options[] = {
    {OPTION_ACCELMETHOD,	"AccelMethod",	OPTV_ANYSTR,	{0},	FALSE},
    {OPTION_NOACCEL,	"NoAccel",	OPTV_BOOLEAN,	{0},	FALSE},
-   {OPTION_SW_CURSOR,	"SWcursor",	OPTV_BOOLEAN,	{0},	FALSE},
    {OPTION_CACHE_LINES,	"CacheLines",	OPTV_INTEGER,	{0},	FALSE},
    {OPTION_DRI,		"DRI",		OPTV_BOOLEAN,	{0},	TRUE},
    {OPTION_XVIDEO,	"XVideo",	OPTV_BOOLEAN,	{0},	TRUE},
@@ -1503,6 +1501,10 @@ I830LoadSyms(ScrnInfoPtr pScrn)
 	return FALSE;
     xf86LoaderReqSymLists(I810vgahwSymbols, NULL);
 
+    if (!xf86LoadSubModule(pScrn, "ramdac"))
+       return FALSE;
+    xf86LoaderReqSymLists(I810ramdacSymbols, NULL);
+
     return TRUE;
 }
 
@@ -1622,10 +1624,6 @@ I830AccelMethodInit(ScrnInfoPtr pScrn)
 		   accel_name[pI830->accel]);
     }
 
-    if (xf86ReturnOptValBool(pI830->Options, OPTION_SW_CURSOR, FALSE)) {
-	pI830->SWCursor = TRUE;
-    }
-
     pI830->directRenderingType = DRI_NONE;
     if (!xf86ReturnOptValBool(pI830->Options, OPTION_DRI, TRUE))
 	pI830->directRenderingType = DRI_DISABLED;
@@ -1974,13 +1972,6 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
    default:
       break;
    }
-   if (!pI830->SWCursor) {
-      if (!xf86LoadSubModule(pScrn, "ramdac")) {
-	 PreInitCleanup(pScrn);
-	 return FALSE;
-      }
-      xf86LoaderReqSymLists(I810ramdacSymbols, NULL);
-   }
 
    if (!pI830->use_drm_mode) {
        i830CompareRegsToSnapshot(pScrn, "After PreInit");
@@ -3032,8 +3023,6 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
    /* If DRI hasn't been explicitly disabled, try to initialize it.
     * It will be used by the memory allocator.
     */
-   if (pI830->directRenderingType == DRI_NONE && pI830->SWCursor)
-       pI830->directRenderingType = DRI_DISABLED;
    if (!pI830->can_resize && pI830->directRenderingType == DRI_NONE && I830DRIScreenInit(pScreen))
        pI830->directRenderingType = DRI_XF86DRI;
 
@@ -3162,9 +3151,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
     * InitGLXVisuals call back.
     */
    if (pI830->directRenderingType == DRI_XF86DRI) {
-      if (pI830->accel == ACCEL_NONE || pI830->SWCursor) {
+      if (pI830->accel == ACCEL_NONE) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "DRI is disabled because it "
-		    "needs HW cursor and 2D accel.\n");
+		    "needs 2D acceleration.\n");
 	 pI830->directRenderingType = DRI_NONE;
       }
    }
@@ -3257,13 +3246,10 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
    xf86SetSilkenMouse(pScreen);
    miDCInitialize(pScreen, xf86GetPointerScreenFuncs());
 
-   if (!pI830->SWCursor) {
-      xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing HW Cursor\n");
-      if (!I830CursorInit(pScreen))
-	 xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
-		    "Hardware cursor initialization failed\n");
-   } else
-      xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing SW Cursor!\n");
+   xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Initializing HW Cursor\n");
+   if (!I830CursorInit(pScreen))
+      xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+		 "Hardware cursor initialization failed\n");
 
 #ifdef XF86DRI
    /* Must be called before EnterVT, so we can acquire the DRI lock when
@@ -3571,8 +3557,7 @@ I830EnterVT(int scrnIndex, int flags)
 	   i830_stop_ring(pScrn, FALSE);
 	   i830_start_ring(pScrn);
        }
-       if (!pI830->SWCursor)
-	   I830InitHWCursor(pScrn);
+       I830InitHWCursor(pScrn);
 
        /* Tell the BIOS that we're in control of mode setting now. */
        i830_init_bios_control(pScrn);
diff --git a/src/i830_memory.c b/src/i830_memory.c
index 0fd5d5b..84262af 100644
--- a/src/i830_memory.c
+++ b/src/i830_memory.c
@@ -1448,11 +1448,10 @@ i830_allocate_2d_memory(ScrnInfoPtr pScrn)
 	i830_setup_fb_compression(pScrn);
 
     /* Next, allocate other fixed-size allocations we have. */
-    if (!pI830->SWCursor && !i830_allocate_cursor_buffers(pScrn)) {
-	xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
-		   "Disabling HW cursor because the cursor memory "
-		   "allocation failed.\n");
-	pI830->SWCursor = TRUE;
+    if (!i830_allocate_cursor_buffers(pScrn)) {
+	xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+		   "Failed to allocate HW cursor space.\n");
+	return FALSE;
     }
 
     if (pI830->memory_manager == NULL) {
@@ -1997,7 +1996,7 @@ i830_bind_all_memory(ScrnInfoPtr pScrn)
 		FatalError("Couldn't bind memory for BO %s\n", mem->name);
 	}
     }
-    if (!pI830->SWCursor && !pI830->use_drm_mode)
+    if (!pI830->use_drm_mode)
 	i830_update_cursor_offsets(pScrn);
 
     return TRUE;
commit 917b20ead3cacf1e88314f20edde6a02b97b96d7
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 27 23:01:28 2009 -0800

    Remove StolenOnly support.
    
    We rely on having AGPGART present to successfully allocate video memory as
    we configure it by default.  Admit that fact, and remove support for
    non-AGPGART/KMS setups.

diff --git a/src/i830.h b/src/i830.h
index 3d1a30a..ffb2732 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -609,8 +609,6 @@ typedef struct _I830Rec {
 
    Bool tv_present; /* TV connector present (from VBIOS) */
 
-   Bool StolenOnly;
-
    /* Driver phase/state information */
    Bool preinit;
    Bool starting;
diff --git a/src/i830_driver.c b/src/i830_driver.c
index da560d8..908614a 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -1915,17 +1915,6 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
        return FALSE;
    }
 
-   /*
-    * XXX If we knew the pre-initialised GTT format for certain, we could
-    * probably figure out the physical address even in the StolenOnly case.
-    */
-   if (pI830->StolenOnly && pI830->CursorNeedsPhysical &&
-	      !pI830->SWCursor) {
-      xf86DrvMsg(pScrn->scrnIndex, X_PROBED,
-		 "HW Cursor disabled because it needs agpgart memory.\n");
-      pI830->SWCursor = TRUE;
-   }
-
    if (pScrn->modes == NULL) {
       xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "No modes.\n");
       PreInitCleanup(pScrn);
@@ -2874,25 +2863,19 @@ I830AdjustMemory(ScreenPtr pScreen)
    /* Limit videoRam to how much we might be able to allocate from AGP */
    sys_mem = I830CheckAvailableMemory(pScrn);
    if (sys_mem == -1) {
-      if (pScrn->videoRam > pI830->stolen_size / KB(1)) {
+      xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+		 "/dev/agpgart is either not available, or no memory "
+		 "is available\nfor allocation.  Please enable agpgart\n.");
+      pScrn->videoRam = pI830->stolen_size / KB(1);
+   }
+   if (sys_mem + (pI830->stolen_size / 1024) < pScrn->videoRam) {
+      pScrn->videoRam = sys_mem + (pI830->stolen_size / 1024);
+      from = X_PROBED;
+      if (sys_mem + (pI830->stolen_size / 1024) <
+	  pI830->pEnt->device->videoRam) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
-		    "/dev/agpgart is either not available, or no memory "
-		    "is available\nfor allocation.  "
-		    "Using pre-allocated memory only.\n");
-	 pScrn->videoRam = pI830->stolen_size / KB(1);
-      }
-      pI830->StolenOnly = TRUE;
-   } else {
-      if (sys_mem + (pI830->stolen_size / 1024) < pScrn->videoRam) {
-	 pScrn->videoRam = sys_mem + (pI830->stolen_size / 1024);
-	 from = X_PROBED;
-	 if (sys_mem + (pI830->stolen_size / 1024) <
-	     pI830->pEnt->device->videoRam)
-	 {
-	    xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
-		       "VideoRAM reduced to %d kByte "
-		       "(limited to available sysmem)\n", pScrn->videoRam);
-	 }
+		    "VideoRAM reduced to %d kByte "
+		    "(limited to available sysmem)\n", pScrn->videoRam);
       }
    }
 
@@ -3135,9 +3118,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
 #ifdef I830_XV
    pI830->XvEnabled = !pI830->XvDisabled;
    if (pI830->XvEnabled) {
-      if (pI830->accel == ACCEL_NONE || pI830->StolenOnly) {
+      if (pI830->accel == ACCEL_NONE) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Xv is disabled because it "
-		    "needs 2D accel and AGPGART.\n");
+		    "needs 2D acceleration.\n");
 	 pI830->XvEnabled = FALSE;
       }
    }
@@ -3179,9 +3162,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
     * InitGLXVisuals call back.
     */
    if (pI830->directRenderingType == DRI_XF86DRI) {
-      if (pI830->accel == ACCEL_NONE || pI830->SWCursor || pI830->StolenOnly) {
+      if (pI830->accel == ACCEL_NONE || pI830->SWCursor) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "DRI is disabled because it "
-		    "needs HW cursor, 2D accel and AGPGART.\n");
+		    "needs HW cursor and 2D accel.\n");
 	 pI830->directRenderingType = DRI_NONE;
       }
    }
diff --git a/src/i830_memory.c b/src/i830_memory.c
index 96f4008..0fd5d5b 100644
--- a/src/i830_memory.c
+++ b/src/i830_memory.c
@@ -1431,8 +1431,7 @@ i830_allocate_2d_memory(ScrnInfoPtr pScrn)
     long size;
 
     if (!pI830->use_drm_mode) {
-	if (!pI830->StolenOnly &&
-	    (!xf86AgpGARTSupported() || !xf86AcquireGART(pScrn->scrnIndex))) {
+	if (!xf86AgpGARTSupported() || !xf86AcquireGART(pScrn->scrnIndex)) {
 	    xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
 		       "AGP GART support is either not available or cannot "
 		       "be used.\n"
@@ -1970,7 +1969,7 @@ i830_bind_all_memory(ScrnInfoPtr pScrn)
 {
     I830Ptr pI830 = I830PTR(pScrn);
 
-    if (pI830->StolenOnly == TRUE || pI830->memory_list == NULL)
+    if (pI830->memory_list == NULL)
 	return TRUE;
 
     if (pI830->use_drm_mode || (xf86AgpGARTSupported() &&
@@ -2010,9 +2009,6 @@ i830_unbind_all_memory(ScrnInfoPtr pScrn)
 {
     I830Ptr pI830 = I830PTR(pScrn);
 
-    if (pI830->StolenOnly == TRUE)
-	return TRUE;
-
     if (pI830->use_drm_mode || (xf86AgpGARTSupported() &&
 				pI830->gtt_acquired)) {
 	i830_memory *mem;
commit 73b7190421132ad73179c3fb7bb0e06c427dce5c
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 27 22:51:22 2009 -0800

    intel: Nuke shared-entity support (zaphod mode).
    
    It's been broken for years now, and KMS offers a much better chance of getting
    this working sensibly without making a mess of the 2D driver.

diff --git a/src/i810_driver.c b/src/i810_driver.c
index c10e15b..6ae388d 100644
--- a/src/i810_driver.c
+++ b/src/i810_driver.c
@@ -620,8 +620,6 @@ static Bool intel_pci_probe (DriverPtr		driver,
 {
     ScrnInfoPtr	    scrn = NULL;
     EntityInfoPtr   entity;
-    I830EntPtr	    i830_ent = NULL;
-    DevUnion	    *private;
 
     scrn = xf86ConfigPciEntity (scrn, 0, entity_num, I810PciChipsets,
 				NULL,
@@ -651,44 +649,7 @@ static Bool intel_pci_probe (DriverPtr		driver,
 	    scrn->ValidMode = I810ValidMode;
 	    break;
 #endif
-	case PCI_CHIP_845_G:
-	case PCI_CHIP_I865_G:
-	    /*
-	     * These two chips have only one pipe, and
-	     * cannot do dual-head
-	     */
-	    I830InitpScrn(scrn);
-	    break;
 	default:
-	    /*
-	     * Everything else is an i830-ish dual-pipe chip
-	     */
-	    xf86SetEntitySharable(entity_num);
-
-	    /* Allocate an entity private if necessary */		
-	    if (I830EntityIndex < 0)					
-		I830EntityIndex = xf86AllocateEntityPrivateIndex();	
-
-	    private = xf86GetEntityPrivate(scrn->entityList[0],
-					   I830EntityIndex);	
-	    i830_ent = private->ptr;
-	    if (!i830_ent)
-	    {
-		private->ptr = xnfcalloc(sizeof(I830EntRec), 1);
-		i830_ent = private->ptr;
-		i830_ent->lastInstance = -1;
-	    }
-
-	    /*
-	     * Set the entity instance for this instance of the driver.
-	     * For dual head per card, instance 0 is the "master"
-	     * instance, driving the primary head, and instance 1 is
-	     * the "slave".
-	     */
-	    i830_ent->lastInstance++;
-	    xf86SetEntityInstanceForScreen(scrn,			
-					   scrn->entityList[0],
-					   i830_ent->lastInstance);	
 	    I830InitpScrn(scrn);
 	    break;
 	}
@@ -708,7 +669,6 @@ static Bool
 I810Probe(DriverPtr drv, int flags)
 {
    int i, numUsed, numDevSections, *usedChips;
-   I830EntPtr pI830Ent = NULL;					
    DevUnion *pPriv;						
    GDevPtr *devSections;
    Bool foundScreen = FALSE;
@@ -790,8 +750,6 @@ I810Probe(DriverPtr drv, int flags)
 	    switch (pEnt->chipset) {
 	    case PCI_CHIP_845_G:
 	    case PCI_CHIP_I865_G:
-	       I830InitpScrn(pScrn);
-               break;
 	    case PCI_CHIP_I830_M:
 	    case PCI_CHIP_I855_GM:
 	    case PCI_CHIP_I915_G:
@@ -816,31 +774,6 @@ I810Probe(DriverPtr drv, int flags)
 	    case PCI_CHIP_G45_G:
 	    case PCI_CHIP_Q45_G:
 	    case PCI_CHIP_G41_G:
-    	       xf86SetEntitySharable(usedChips[i]);
-
-    	       /* Allocate an entity private if necessary */		
-    	       if (I830EntityIndex < 0)					
-		  I830EntityIndex = xf86AllocateEntityPrivateIndex();	
-
-    	       pPriv = xf86GetEntityPrivate(pScrn->entityList[0],
-						I830EntityIndex);	
-    	       if (!pPriv->ptr) {
-		  pPriv->ptr = xnfcalloc(sizeof(I830EntRec), 1);
-		  pI830Ent = pPriv->ptr;
-		  pI830Ent->lastInstance = -1;
-    	       } else {
-		   pI830Ent = pPriv->ptr;
-    	       }
-
-    	       /*
-		* Set the entity instance for this instance of the driver.
-     	        * For dual head per card, instance 0 is the "master"
-     	        * instance, driving the primary head, and instance 1 is
-     	        * the "slave".
-     	        */
-    	       pI830Ent->lastInstance++;
-               xf86SetEntityInstanceForScreen(pScrn,			
-			pScrn->entityList[0], pI830Ent->lastInstance);	
 	       I830InitpScrn(pScrn);
 	       break;
 #ifndef I830_ONLY
diff --git a/src/i830.h b/src/i830.h
index cd9c38a..3d1a30a 100644
--- a/src/i830.h
+++ b/src/i830.h
@@ -212,17 +212,6 @@ typedef struct {
    int space;
 } I830RingBuffer;
 
-typedef struct {
-   int            lastInstance;
-   int            refCount;
-   ScrnInfoPtr    pScrn_1;
-   ScrnInfoPtr    pScrn_2;
-   int            RingRunning;
-#ifdef I830_XV
-   int            XvInUse;
-#endif
-} I830EntRec, *I830EntPtr;
-
 /* store information about an Ixxx DVO */
 /* The i830->i865 use multiple DVOs with multiple i2cs */
 /* the i915, i945 have a single sDVO i2c bus - which is different */
@@ -381,9 +370,6 @@ typedef struct _I830Rec {
    unsigned char *FbBase;
    int cpp;
 
-   I830EntPtr entityPrivate;	
-   int init;
-
    unsigned int bufferOffset;		/* for I830SelectBuffer */
    BoxRec FbMemBox;
    BoxRec FbMemBox2;
@@ -404,7 +390,6 @@ typedef struct _I830Rec {
    int gtt_acquired;		/**< whether we currently own the AGP */
 
    i830_memory *front_buffer;
-   i830_memory *front_buffer_2;
    i830_memory *compressed_front_buffer;
    i830_memory *compressed_ll_buffer;
    /* One big buffer for all cursors for kernels that support this */
@@ -413,14 +398,13 @@ typedef struct _I830Rec {
    i830_memory *cursor_mem_classic[2];
    i830_memory *cursor_mem_argb[2];
    i830_memory *xaa_scratch;
-   i830_memory *xaa_scratch_2;
 #ifdef I830_USE_EXA
    i830_memory *exa_offscreen;
 #endif
    i830_memory *fake_bufmgr_mem;
 
    /* Regions allocated either from the above pools, or from agpgart. */
-   I830RingBuffer *LpRing;
+   I830RingBuffer ring;
 
    /** Number of bytes being emitted in the current BEGIN_LP_RING */
    unsigned int ring_emitting;
@@ -562,7 +546,7 @@ typedef struct _I830Rec {
    int colorKey;
    XF86VideoAdaptorPtr adaptor;
    ScreenBlockHandlerProcPtr BlockHandler;
-   Bool *overlayOn;
+   Bool overlayOn;
 
    struct {
       drm_intel_bo *gen4_vs_bo;
@@ -723,7 +707,7 @@ typedef struct _I830Rec {
    uint32_t saveRAMCLK_GATE_D;
    uint32_t savePWRCTXA;
 
-   enum last_3d *last_3d;
+   enum last_3d last_3d;
 
    Bool use_drm_mode;
    Bool kernel_exec_fencing;
@@ -875,7 +859,6 @@ Bool i830_allocate_xvmc_buffer(ScrnInfoPtr pScrn, const char *name,
 extern void i830_update_front_offset(ScrnInfoPtr pScrn);
 extern uint32_t i830_create_new_fb(ScrnInfoPtr pScrn, int width, int height,
 				   int *pitch);
-extern Bool I830IsPrimary(ScrnInfoPtr pScrn);
 
 Bool
 i830_tiled_width(I830Ptr i830, int *width, int cpp);
@@ -985,7 +968,7 @@ i830_wait_ring_idle(ScrnInfoPtr pScrn)
    I830Ptr pI830 = I830PTR(pScrn);
 
    if (pI830->accel != ACCEL_NONE)
-       I830WaitLpRing(pScrn, pI830->LpRing->mem->size - 8, 0);
+       I830WaitLpRing(pScrn, pI830->ring.mem->size - 8, 0);
 }
 
 static inline int i830_fb_compression_supported(I830Ptr pI830)
diff --git a/src/i830_accel.c b/src/i830_accel.c
index 9155c92..9f5bcb5 100644
--- a/src/i830_accel.c
+++ b/src/i830_accel.c
@@ -96,7 +96,7 @@ int
 I830WaitLpRing(ScrnInfoPtr pScrn, int n, int timeout_millis)
 {
    I830Ptr pI830 = I830PTR(pScrn);
-   I830RingBuffer *ring = pI830->LpRing;
+   I830RingBuffer *ring = &pI830->ring;
    int iters = 0;
    unsigned int start = 0;
    unsigned int now = 0;
@@ -188,8 +188,6 @@ I830Sync(ScrnInfoPtr pScrn)
    }
 #endif
 
-   if (pI830->entityPrivate && !pI830->entityPrivate->RingRunning) return;
-
    I830EmitFlush(pScrn);
 
    intel_batch_flush(pScrn, TRUE);
diff --git a/src/i830_batchbuffer.c b/src/i830_batchbuffer.c
index 33da43e..ff5f0c2 100644
--- a/src/i830_batchbuffer.c
+++ b/src/i830_batchbuffer.c
@@ -122,7 +122,7 @@ intel_next_batch(ScrnInfoPtr pScrn)
      * so we have to reinitialize our 3D state per batch.
      */
     if (pI830->directRenderingType == DRI_DRI2)
-	*pI830->last_3d = LAST_3D_OTHER;
+	pI830->last_3d = LAST_3D_OTHER;
 }
 
 void
diff --git a/src/i830_debug.c b/src/i830_debug.c
index d99af57..ed8843e 100644
--- a/src/i830_debug.c
+++ b/src/i830_debug.c
@@ -1481,9 +1481,9 @@ i830_valid_chain (ScrnInfoPtr pScrn, unsigned int ring, unsigned int end)
     
     head = (INREG (LP_RING + RING_HEAD)) & I830_HEAD_MASK;
     tail = INREG (LP_RING + RING_TAIL) & I830_TAIL_MASK;
-    mask = pI830->LpRing->tail_mask;
+    mask = pI830->ring.tail_mask;
     
-    virt = pI830->LpRing->virtual_start;
+    virt = pI830->ring.virtual_start;
     ErrorF ("Ring at virtual %p head 0x%x tail 0x%x count %d\n",
 	    virt, head, tail, (((tail + mask + 1) - head) & mask) >> 2);
 
@@ -1581,9 +1581,9 @@ i830_dump_ring(ScrnInfoPtr pScrn, uint32_t acthd)
     
     head = (INREG (LP_RING + RING_HEAD)) & I830_HEAD_MASK;
     tail = INREG (LP_RING + RING_TAIL) & I830_TAIL_MASK;
-    mask = pI830->LpRing->tail_mask;
+    mask = pI830->ring.tail_mask;
     
-    virt = pI830->LpRing->virtual_start;
+    virt = pI830->ring.virtual_start;
     ErrorF ("Ring at virtual %p head 0x%x tail 0x%x count %d acthd 0x%x\n",
 	    virt, head, tail, (((tail + mask + 1) - head) & mask) >> 2, acthd);
 
@@ -1729,8 +1729,6 @@ i830_check_error_state(ScrnInfoPtr pScrn)
     int errors = 0;
     unsigned long temp, head, tail;
 
-    if (!I830IsPrimary(pScrn)) return TRUE;
-
     temp = INREG16(ESR);
     if (temp != 0) {
 	Bool vertex_max = !IS_I965G(pI830) && (temp & ERR_VERTEX_MAX);
diff --git a/src/i830_display.c b/src/i830_display.c
index e243bfd..3139d40 100644
--- a/src/i830_display.c
+++ b/src/i830_display.c
@@ -469,11 +469,8 @@ i830PipeSetBase(xf86CrtcPtr crtc, int x, int y)
 	Start = (char *)crtc->rotatedData - (char *)pI830->FbBase;
 	Offset = 0;
 	Stride = intel_crtc->rotate_mem->pitch;
-    } else if (I830IsPrimary(pScrn)) {
-	Start = pI830->front_buffer->offset;
     } else {
-	I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-	Start = pI8301->front_buffer_2->offset;
+	Start = pI830->front_buffer->offset;
     }
 
     crtc->x = x;
diff --git a/src/i830_dri.c b/src/i830_dri.c
index 96c711e..b7ebd92 100644
--- a/src/i830_dri.c
+++ b/src/i830_dri.c
@@ -146,7 +146,7 @@ static Bool
 I830InitDma(ScrnInfoPtr pScrn)
 {
    I830Ptr pI830 = I830PTR(pScrn);
-   I830RingBuffer *ring = pI830->LpRing;
+   I830RingBuffer *ring = &pI830->ring;
    I830DRIPtr pI830DRI = (I830DRIPtr) pI830->pDRIInfo->devPrivate;
    drmI830Init info;
 
@@ -773,9 +773,9 @@ I830DRIMapHW(ScreenPtr pScreen)
 
    if (!pI830->memory_manager) {
        if (drmAddMap(pI830->drmSubFD,
-		     (drm_handle_t)pI830->LpRing->mem->offset +
+		     (drm_handle_t)pI830->ring.mem->offset +
 		     pI830->LinearAddr,
-		     pI830->LpRing->mem->size, DRM_AGP, 0,
+		     pI830->ring.mem->size, DRM_AGP, 0,
 		     (drmAddress) &pI830->ring_map) < 0) {
 	   xf86DrvMsg(pScreen->myNum, X_ERROR,
 		      "[drm] drmAddMap(ring_map) failed. Disabling DRI\n");
@@ -1004,7 +1004,7 @@ I830DRISwapContext(ScreenPtr pScreen, DRISyncType syncType,
       if (I810_DEBUG & DEBUG_VERBOSE_DRI)
 	 ErrorF("i830DRISwapContext (in)\n");
 
-      *pI830->last_3d = LAST_3D_OTHER;
+      pI830->last_3d = LAST_3D_OTHER;
 
       if (!pScrn->vtSema)
      	 return;
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 5504025..da560d8 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -711,9 +711,8 @@ I830MapMem(ScrnInfoPtr pScrn)
       return FALSE;
 #endif
 
-   if (I830IsPrimary(pScrn) && pI830->LpRing->mem != NULL) {
-      pI830->LpRing->virtual_start =
-	 pI830->FbBase + pI830->LpRing->mem->offset;
+   if (pI830->ring.mem != NULL) {
+      pI830->ring.virtual_start = pI830->FbBase + pI830->ring.mem->offset;
    }
 
    return TRUE;
@@ -1062,32 +1061,11 @@ PreInitCleanup(ScrnInfoPtr pScrn)
 {
    I830Ptr pI830 = I830PTR(pScrn);
 
-   if (I830IsPrimary(pScrn)) {
-      if (pI830->entityPrivate)
-	 pI830->entityPrivate->pScrn_1 = NULL;
-   } else {
-      if (pI830->entityPrivate)
-         pI830->entityPrivate->pScrn_2 = NULL;
-   }
    if (pI830->MMIOBase)
       I830UnmapMMIO(pScrn);
    I830FreeRec(pScrn);
 }
 
-Bool
-I830IsPrimary(ScrnInfoPtr pScrn)
-{
-   I830Ptr pI830 = I830PTR(pScrn);
-
-   if (xf86IsEntityShared(pScrn->entityList[0])) {
-	if (pI830->init == 0) return TRUE;
-	else return FALSE;
-   }
-
-   return TRUE;
-}
-
-
 /*
  * Adjust *width to allow for tiling if possible
  */
@@ -1825,7 +1803,6 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
    I830Ptr pI830;
    rgb defaultWeight = { 0, 0, 0 };
    EntityInfoPtr pEnt;
-   I830EntPtr pI830Ent = NULL;
    int flags24;
    Gamma zeros = { 0.0, 0.0, 0.0 };
    int drm_mode_setting;
@@ -1871,43 +1848,11 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
 			  pI830->PciInfo->func);
 #endif
 
-    /* Allocate an entity private if necessary */
-    if (xf86IsEntityShared(pScrn->entityList[0])) {
-	pI830Ent = xf86GetEntityPrivate(pScrn->entityList[0],
-					I830EntityIndex)->ptr;
-        pI830->entityPrivate = pI830Ent;
-    } else
-        pI830->entityPrivate = NULL;
-
    if (xf86RegisterResources(pI830->pEnt->index, NULL, ResNone)) {
       PreInitCleanup(pScrn);
       return FALSE;
    }
 
-   if (xf86IsEntityShared(pScrn->entityList[0])) {
-      if (xf86IsPrimInitDone(pScrn->entityList[0])) {
-	 pI830->init = 1;
-
-         if (!pI830Ent->pScrn_1) {
-            xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- 		 "Failed to setup second head due to primary head failure.\n");
-	    return FALSE;
-         }
-      } else {
-         xf86SetPrimInitDone(pScrn->entityList[0]);
-	 pI830->init = 0;
-      }
-   }
-
-   if (xf86IsEntityShared(pScrn->entityList[0])) {
-      if (!I830IsPrimary(pScrn)) {
-         pI830Ent->pScrn_2 = pScrn;
-      } else {
-         pI830Ent->pScrn_1 = pScrn;
-         pI830Ent->pScrn_2 = NULL;
-      }
-   }
-
    pScrn->racMemFlags = RAC_FB | RAC_COLORMAP;
    pScrn->monitor = pScrn->confScreen->monitor;
    pScrn->progClock = TRUE;
@@ -1974,14 +1919,7 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
     * XXX If we knew the pre-initialised GTT format for certain, we could
     * probably figure out the physical address even in the StolenOnly case.
     */
-   if (!I830IsPrimary(pScrn)) {
-        I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-	if (!pI8301->SWCursor) {
-          xf86DrvMsg(pScrn->scrnIndex, X_PROBED,
-		 "Using HW Cursor because it's enabled on primary head.\n");
-          pI830->SWCursor = FALSE;
-        }
-   } else if (pI830->StolenOnly && pI830->CursorNeedsPhysical &&
+   if (pI830->StolenOnly && pI830->CursorNeedsPhysical &&
 	      !pI830->SWCursor) {
       xf86DrvMsg(pScrn->scrnIndex, X_PROBED,
 		 "HW Cursor disabled because it needs agpgart memory.\n");
@@ -2103,11 +2041,6 @@ i830_stop_ring(ScrnInfoPtr pScrn, Bool flush)
 
    DPRINTF(PFX, "ResetState: flush is %s\n", BOOLTOSTRING(flush));
 
-   if (!I830IsPrimary(pScrn)) return;
-
-   if (pI830->entityPrivate)
-      pI830->entityPrivate->RingRunning = 0;
-
    /* Flush the ring buffer (if enabled), then disable it. */
    if (pI830->accel != ACCEL_NONE) {
       temp = INREG(LP_RING + RING_LEN);
@@ -2134,31 +2067,26 @@ i830_start_ring(ScrnInfoPtr pScrn)
    if (pI830->accel == ACCEL_NONE)
       return;
 
-   if (!I830IsPrimary(pScrn)) return;
-
-   if (pI830->entityPrivate)
-      pI830->entityPrivate->RingRunning = 1;
-
    OUTREG(LP_RING + RING_LEN, 0);
    OUTREG(LP_RING + RING_TAIL, 0);
    OUTREG(LP_RING + RING_HEAD, 0);
 
-   assert((pI830->LpRing->mem->offset & I830_RING_START_MASK) ==
-	   pI830->LpRing->mem->offset);
+   assert((pI830->ring.mem->offset & I830_RING_START_MASK) ==
+	   pI830->ring.mem->offset);
 
    /* Don't care about the old value.  Reserved bits must be zero anyway. */
-   itemp = pI830->LpRing->mem->offset;
+   itemp = pI830->ring.mem->offset;
    OUTREG(LP_RING + RING_START, itemp);
 
-   if (((pI830->LpRing->mem->size - 4096) & I830_RING_NR_PAGES) !=
-       pI830->LpRing->mem->size - 4096) {
+   if (((pI830->ring.mem->size - 4096) & I830_RING_NR_PAGES) !=
+       pI830->ring.mem->size - 4096) {
       xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
 		 "I830SetRingRegs: Ring buffer size - 4096 (%lx) violates its "
-		 "mask (%x)\n", pI830->LpRing->mem->size - 4096,
+		 "mask (%x)\n", pI830->ring.mem->size - 4096,
 		 I830_RING_NR_PAGES);
    }
    /* Don't care about the old value.  Reserved bits must be zero anyway. */
-   itemp = (pI830->LpRing->mem->size - 4096) & I830_RING_NR_PAGES;
+   itemp = (pI830->ring.mem->size - 4096) & I830_RING_NR_PAGES;
    itemp |= (RING_NO_REPORT | RING_VALID);
    OUTREG(LP_RING + RING_LEN, itemp);
    i830_refresh_ring(pScrn);
@@ -2172,14 +2100,14 @@ i830_refresh_ring(ScrnInfoPtr pScrn)
    /* If we're reaching RefreshRing as a result of grabbing the DRI lock
     * before we've set up the ringbuffer, don't bother.
     */
-   if (pI830->LpRing->mem == NULL)
+   if (pI830->ring.mem == NULL)
        return;
 
-   pI830->LpRing->head = INREG(LP_RING + RING_HEAD) & I830_HEAD_MASK;
-   pI830->LpRing->tail = INREG(LP_RING + RING_TAIL);
-   pI830->LpRing->space = pI830->LpRing->head - (pI830->LpRing->tail + 8);
-   if (pI830->LpRing->space < 0)
-      pI830->LpRing->space += pI830->LpRing->mem->size;
+   pI830->ring.head = INREG(LP_RING + RING_HEAD) & I830_HEAD_MASK;
+   pI830->ring.tail = INREG(LP_RING + RING_TAIL);
+   pI830->ring.space = pI830->ring.head - (pI830->ring.tail + 8);
+   if (pI830->ring.space < 0)
+      pI830->ring.space += pI830->ring.mem->size;
    i830MarkSync(pScrn);
 }
 
@@ -2695,7 +2623,7 @@ IntelEmitInvarientState(ScrnInfoPtr pScrn)
    /* If we've emitted our state since the last clobber by another client,
     * skip it.
     */
-   if (*pI830->last_3d != LAST_3D_OTHER)
+   if (pI830->last_3d != LAST_3D_OTHER)
       return;
 
    if (!IS_I965G(pI830))
@@ -3051,7 +2979,6 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
    vgaHWPtr hwp = NULL;
    I830Ptr pI830;
    VisualPtr visual;
-   I830Ptr pI8301 = NULL;
    MessageType from;
 
    pScrn = xf86Screens[pScreen->myNum];
@@ -3169,31 +3096,8 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
    xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "Tiling %sabled\n", pI830->tiling ?
 	      "en" : "dis");
 
-   if (I830IsPrimary(pScrn)) {
-      /* Alloc our pointers for the primary head */
-      if (!pI830->LpRing)
-         pI830->LpRing = xcalloc(1, sizeof(I830RingBuffer));
-      if (!pI830->overlayOn)
-         pI830->overlayOn = xalloc(sizeof(Bool));
-      if (!pI830->last_3d)
-         pI830->last_3d = xalloc(sizeof(enum last_3d));
-      if (!pI830->LpRing || !pI830->overlayOn || !pI830->last_3d) {
-         xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
-		 "Could not allocate primary data structures.\n");
-         return FALSE;
-      }
-      *pI830->last_3d = LAST_3D_OTHER;
-      *pI830->overlayOn = FALSE;
-      if (pI830->entityPrivate)
-         pI830->entityPrivate->XvInUse = -1;
-   } else {
-      /* Make our second head point to the first heads structures */
-      pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-      pI830->LpRing = pI8301->LpRing;
-      pI830->overlay_regs = pI8301->overlay_regs;
-      pI830->overlayOn = pI8301->overlayOn;
-      pI830->last_3d = pI8301->last_3d;
-   }
+   pI830->last_3d = LAST_3D_OTHER;
+   pI830->overlayOn = FALSE;
 
 #ifdef I830_XV
     /*
@@ -3231,12 +3135,6 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
 #ifdef I830_XV
    pI830->XvEnabled = !pI830->XvDisabled;
    if (pI830->XvEnabled) {
-      if (!I830IsPrimary(pScrn)) {
-         if (!pI8301->XvEnabled || pI830->accel == ACCEL_NONE) {
-            pI830->XvEnabled = FALSE;
-	    xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Xv is disabled.\n");
-         }
-      } else
       if (pI830->accel == ACCEL_NONE || pI830->StolenOnly) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Xv is disabled because it "
 		    "needs 2D accel and AGPGART.\n");
@@ -3248,7 +3146,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
 #endif
 
    if (pI830->accel != ACCEL_NONE && !pI830->use_drm_mode) {
-      if (pI830->memory_manager == NULL && pI830->LpRing->mem->size == 0) {
+      if (pI830->memory_manager == NULL && pI830->ring.mem->size == 0) {
 	  xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
 		     "Disabling acceleration because the ring buffer "
 		      "allocation failed.\n");
@@ -3281,7 +3179,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
     * InitGLXVisuals call back.
     */
    if (pI830->directRenderingType == DRI_XF86DRI) {
-      if (pI830->accel == ACCEL_NONE || pI830->SWCursor || (pI830->StolenOnly && I830IsPrimary(pScrn))) {
+      if (pI830->accel == ACCEL_NONE || pI830->SWCursor || pI830->StolenOnly) {
 	 xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "DRI is disabled because it "
 		    "needs HW cursor, 2D accel and AGPGART.\n");
 	 pI830->directRenderingType = DRI_NONE;
@@ -3301,11 +3199,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
        I830SwapPipes(pScrn);
 #endif
 
-   if (I830IsPrimary(pScrn)) {
-        pScrn->fbOffset = pI830->front_buffer->offset;
-   } else {
-       pScrn->fbOffset = pI8301->front_buffer_2->offset;
-   }
+   pScrn->fbOffset = pI830->front_buffer->offset;
 
    pI830->xoffset = (pScrn->fbOffset / pI830->cpp) % pScrn->displayWidth;
    pI830->yoffset = (pScrn->fbOffset / pI830->cpp) / pScrn->displayWidth;
@@ -3321,16 +3215,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
    DPRINTF(PFX, "assert( if(!I830EnterVT(scrnIndex, 0)) )\n");
 
    if (pI830->accel <= ACCEL_XAA) {
-      if (I830IsPrimary(pScrn)) {
-	 if (!I830InitFBManager(pScreen, &(pI830->FbMemBox))) {
-	    xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
-		       "Failed to init memory manager\n");
-	 }
-      } else {
-	 if (!I830InitFBManager(pScreen, &(pI8301->FbMemBox2))) {
-	    xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
-		       "Failed to init memory manager\n");
-	 }
+      if (!I830InitFBManager(pScreen, &(pI830->FbMemBox))) {
+	 xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
+		    "Failed to init memory manager\n");
       }
    }
 
@@ -3550,13 +3437,6 @@ I830LeaveVT(int scrnIndex, int flags)
 
    i830SetHotkeyControl(pScrn, HOTKEY_BIOS_SWITCH);
 
-   if (!I830IsPrimary(pScrn)) {
-   	I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-	if (!pI8301->gtt_acquired) {
-		return;
-	}
-   }
-
 #ifdef XF86DRI
    if (pI830->directRenderingOpen &&
        pI830->directRenderingType == DRI_XF86DRI) {
@@ -3607,8 +3487,7 @@ I830LeaveVT(int scrnIndex, int flags)
 
    intel_batch_teardown(pScrn);
 
-   if (I830IsPrimary(pScrn))
-      i830_unbind_all_memory(pScrn);
+   i830_unbind_all_memory(pScrn);
 
 #ifdef XF86DRI
    if (pI830->memory_manager && !pI830->use_drm_mode) {
@@ -3684,9 +3563,8 @@ I830EnterVT(int scrnIndex, int flags)
    }
 #endif /* XF86DRI */
 
-   if (I830IsPrimary(pScrn))
-      if (!i830_bind_all_memory(pScrn))
-         return FALSE;
+   if (!i830_bind_all_memory(pScrn))
+      return FALSE;
 
    i830_describe_allocations(pScrn, 1, "");
 
@@ -3793,7 +3671,7 @@ I830EnterVT(int scrnIndex, int flags)
    i830SetHotkeyControl(pScrn, HOTKEY_DRIVER_NOTIFY);
 
    /* Mark 3D state as being clobbered and setup the basics */
-   *pI830->last_3d = LAST_3D_OTHER;
+   pI830->last_3d = LAST_3D_OTHER;
    IntelEmitInvarientState(pScrn);
 
    return TRUE;
@@ -3885,16 +3763,7 @@ I830CloseScreen(int scrnIndex, ScreenPtr pScreen)
    }
 #endif
 
-   if (I830IsPrimary(pScrn)) {
-      xf86GARTCloseScreen(scrnIndex);
-
-      xfree(pI830->LpRing);
-      pI830->LpRing = NULL;
-      xfree(pI830->overlayOn);
-      pI830->overlayOn = NULL;
-      xfree(pI830->last_3d);
-      pI830->last_3d = NULL;
-   }
+   xf86GARTCloseScreen(scrnIndex);
 
    pScrn->PointerMoved = pI830->PointerMoved;
    pScrn->vtSema = FALSE;
@@ -3972,9 +3841,6 @@ I830PMEvent(int scrnIndex, pmEvent event, Bool undo)
       break;
    /* This is currently used for ACPI */
    case XF86_APM_CAPABILITY_CHANGED:
-      if (!I830IsPrimary(pScrn))
-         return TRUE;
-
       ErrorF("I830PMEvent: Capability change\n");
 
       SaveScreens(SCREEN_SAVER_FORCER, ScreenSaverReset);
diff --git a/src/i830_memory.c b/src/i830_memory.c
index 62765d6..96f4008 100644
--- a/src/i830_memory.c
+++ b/src/i830_memory.c
@@ -377,9 +377,7 @@ i830_reset_allocations(ScrnInfoPtr pScrn)
 	pI830->cursor_mem_argb[p] = NULL;
     }
     pI830->front_buffer = NULL;
-    pI830->front_buffer_2 = NULL;
     pI830->xaa_scratch = NULL;
-    pI830->xaa_scratch_2 = NULL;
     pI830->exa_offscreen = NULL;
     pI830->overlay_regs = NULL;
     pI830->power_context = NULL;
@@ -388,7 +386,7 @@ i830_reset_allocations(ScrnInfoPtr pScrn)
     pI830->depth_buffer = NULL;
     pI830->textures = NULL;
 #endif
-    pI830->LpRing->mem = NULL;
+    pI830->ring.mem = NULL;
     pI830->fake_bufmgr_mem = NULL;
 }
 
@@ -1054,23 +1052,23 @@ i830_allocate_ringbuffer(ScrnInfoPtr pScrn)
 {
     I830Ptr pI830 = I830PTR(pScrn);
 
-    if (pI830->accel == ACCEL_NONE || pI830->memory_manager || pI830->LpRing->mem != NULL)
+    if (pI830->accel == ACCEL_NONE || pI830->memory_manager || pI830->ring.mem != NULL)
 	return TRUE;
 
     /* We don't have any mechanism in the DRM yet to alert it that we've moved
      * the ringbuffer since init time, so allocate it fixed for its lifetime.
      */
-    pI830->LpRing->mem = i830_allocate_memory(pScrn, "ring buffer",
-					      PRIMARY_RINGBUFFER_SIZE, PITCH_NONE,
-					      GTT_PAGE_SIZE,
-					      NEED_LIFETIME_FIXED, TILE_NONE);
-    if (pI830->LpRing->mem == NULL) {
+    pI830->ring.mem = i830_allocate_memory(pScrn, "ring buffer",
+					   PRIMARY_RINGBUFFER_SIZE, PITCH_NONE,
+					   GTT_PAGE_SIZE,
+					   NEED_LIFETIME_FIXED, TILE_NONE);
+    if (pI830->ring.mem == NULL) {
 	xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
 		   "Failed to allocate Ring Buffer space\n");
 	return FALSE;
     }
 
-    pI830->LpRing->tail_mask = pI830->LpRing->mem->size - 1;
+    pI830->ring.tail_mask = pI830->ring.mem->size - 1;
     return TRUE;
 }
 
@@ -1473,20 +1471,10 @@ i830_allocate_2d_memory(ScrnInfoPtr pScrn)
     /* Allocate overlay register space and optional XAA linear allocator
      * space.  The second head in zaphod mode will share the space.
      */
-    if (I830IsPrimary(pScrn) && !pI830->use_drm_mode)
+    if (!pI830->use_drm_mode)
 	i830_allocate_overlay(pScrn);
 #endif
 
-    if (pI830->entityPrivate && pI830->entityPrivate->pScrn_2) {
-	I830EntPtr pI830Ent = pI830->entityPrivate;
-	I830Ptr pI8302 = I830PTR(pI830Ent->pScrn_2);
-
-	pI830->front_buffer_2 =
-	    i830_allocate_framebuffer(pI830Ent->pScrn_2, pI8302,
-				      &pI830->FbMemBox2, TRUE);
-	if (pI830->front_buffer_2 == NULL)
-	    return FALSE;
-    }
     pI830->front_buffer =
 	i830_allocate_framebuffer(pScrn, pI830, &pI830->FbMemBox, FALSE);
     if (pI830->front_buffer == NULL)
@@ -1543,30 +1531,6 @@ i830_allocate_2d_memory(ScrnInfoPtr pScrn)
 		return FALSE;
 	    }
 	}
-
-	/* Let's allocate another scratch buffer for the second head */
-	/* Again, this code won't execute on the dry run pass */
-	if (pI830->entityPrivate && pI830->entityPrivate->pScrn_2)
-	{
-	    pI830->xaa_scratch_2 =
-		i830_allocate_memory(pScrn, "xaa scratch 2",
-				     MAX_SCRATCH_BUFFER_SIZE, PITCH_NONE,
-				     GTT_PAGE_SIZE, NEED_LIFETIME_FIXED,
-				     TILE_NONE);
-	    if (pI830->xaa_scratch_2 == NULL) {
-		pI830->xaa_scratch_2 =
-		    i830_allocate_memory(pScrn, "xaa scratch 2",
-					 MIN_SCRATCH_BUFFER_SIZE, PITCH_NONE,
-					 GTT_PAGE_SIZE, NEED_LIFETIME_FIXED,
-					 TILE_NONE);
-		if (pI830->xaa_scratch_2 == NULL) {
-		    xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
-			       "Failed to allocate secondary scratch "
-			       "buffer space\n");
-		    return FALSE;
-		}
-	    }
-	}
     }
 
     return TRUE;
diff --git a/src/i830_render.c b/src/i830_render.c
index d3b0f7c..5696fa3 100644
--- a/src/i830_render.c
+++ b/src/i830_render.c
@@ -404,7 +404,7 @@ i830_prepare_composite(int op, PicturePtr pSrcPicture,
     i830_exa_check_pitch_3d(pDst);
 
     IntelEmitInvarientState(pScrn);
-    *pI830->last_3d = LAST_3D_RENDER;
+    pI830->last_3d = LAST_3D_RENDER;
 
     if (!i830_get_dest_format(pDstPicture, &dst_format))
 	return FALSE;
diff --git a/src/i830_ring.h b/src/i830_ring.h
index c296d41..062b7ea 100644
--- a/src/i830_ring.h
+++ b/src/i830_ring.h
@@ -34,12 +34,12 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
     if (I810_DEBUG & DEBUG_VERBOSE_RING)				\
 	ErrorF("OUT_RING 0x%08x: 0x%08x, (mask %x)\n",			\
 	       pI830->ring_next, (unsigned int)(n),			\
-	       pI830->LpRing->tail_mask);				\
-    *(volatile uint32_t *)(pI830->LpRing->virtual_start +		\
+	       pI830->ring.tail_mask);					\
+    *(volatile uint32_t *)(pI830->ring.virtual_start +			\
 			   pI830->ring_next) = n;			\
     pI830->ring_used += 4;						\
     pI830->ring_next += 4;						\
-    pI830->ring_next &= pI830->LpRing->tail_mask;			\
+    pI830->ring_next &= pI830->ring.tail_mask;				\
 } while (0)
 
 #define OUT_RING_F(x) do {			\
@@ -60,8 +60,8 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 	FatalError("%s: ADVANCE_LP_RING: under-used allocation %d/%d\n ", \
 		   __FUNCTION__, pI830->ring_used,			\
 		   pI830->ring_emitting);				\
-    pI830->LpRing->tail = pI830->ring_next;				\
-    pI830->LpRing->space -= pI830->ring_used;				\
+    pI830->ring.tail = pI830->ring_next;				\
+    pI830->ring.space -= pI830->ring_used;				\
     if (pI830->ring_next & 0x07)					\
 	FatalError("%s: ADVANCE_LP_RING: "				\
 		   "ring_next (0x%x) isn't on a QWord boundary\n",	\
@@ -80,9 +80,9 @@ do {									\
     pI830->ring_emitting = (n) * 4;					\
     if ((n) & 1)							\
 	pI830->ring_emitting += 4;					\
-    if (pI830->LpRing->space < pI830->ring_emitting)			\
+    if (pI830->ring.space < pI830->ring_emitting)			\
 	WaitRingFunc(pScrn, pI830->ring_emitting, 0);			\
-    pI830->ring_next = pI830->LpRing->tail;				\
+    pI830->ring_next = pI830->ring.tail;				\
     if (I810_DEBUG & DEBUG_VERBOSE_RING)				\
 	ErrorF( "BEGIN_LP_RING %d in %s\n", n, FUNCTION_NAME);		\
     pI830->ring_used = 0;						\
diff --git a/src/i830_video.c b/src/i830_video.c
index 0199747..b4f8890 100644
--- a/src/i830_video.c
+++ b/src/i830_video.c
@@ -448,7 +448,7 @@ i830_overlay_on(ScrnInfoPtr pScrn)
     I830PortPrivPtr	pPriv = pI830->adaptor->pPortPrivates[0].ptr;
     Bool		deactivate = FALSE;
     
-    if (*pI830->overlayOn)
+    if (pI830->overlayOn)
 	return;
 
     /*
@@ -482,7 +482,7 @@ i830_overlay_on(ScrnInfoPtr pScrn)
 	i830_pipe_a_require_deactivate (pScrn);
 
     OVERLAY_DEBUG("overlay_on\n");
-    *pI830->overlayOn = TRUE;
+    pI830->overlayOn = TRUE;
 
     overlay->OCMD |= OVERLAY_ENABLE;
 }
@@ -494,7 +494,7 @@ i830_overlay_continue(ScrnInfoPtr pScrn, Bool update_filter)
     uint32_t		flip_addr;
     I830OverlayRegPtr	overlay = I830OVERLAYREG(pI830);
 
-    if (!*pI830->overlayOn)
+    if (!pI830->overlayOn)
 	return;
 
     if (OVERLAY_NOPHYSICAL(pI830))
@@ -520,7 +520,7 @@ i830_overlay_off(ScrnInfoPtr pScrn)
     I830Ptr pI830 = I830PTR(pScrn);
     I830OverlayRegPtr	overlay = I830OVERLAYREG(pI830);
 
-    if (!*pI830->overlayOn)
+    if (!pI830->overlayOn)
 	return;
 
     /*
@@ -558,7 +558,7 @@ i830_overlay_off(ScrnInfoPtr pScrn)
 	ADVANCE_BATCH();
 	i830WaitSync(pScrn);
     }
-    *pI830->overlayOn = FALSE;
+    pI830->overlayOn = FALSE;
     OVERLAY_DEBUG("overlay_off\n");
 }
 
@@ -1068,7 +1068,6 @@ static void
 I830StopVideo(ScrnInfoPtr pScrn, pointer data, Bool shutdown)
 {
     I830PortPrivPtr pPriv = (I830PortPrivPtr) data;
-    I830Ptr pI830 = I830PTR(pScrn);
 
     if (pPriv->textured)
 	return;
@@ -1080,8 +1079,6 @@ I830StopVideo(ScrnInfoPtr pScrn, pointer data, Bool shutdown)
     if (shutdown) {
 	if (pPriv->videoStatus & CLIENT_VIDEO_ON) {
 	    i830_overlay_off(pScrn);
-	    if (pI830->entityPrivate)
-		pI830->entityPrivate->XvInUse = -1;
 	}
 	if (!pPriv->textured)
 	    drm_intel_bo_unpin(pPriv->buf);
@@ -1197,7 +1194,7 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
 	if ((value < 0) || (value > 1))
 	    return BadValue;
 	/* Do not allow buffer change while playing video */
-	if(!*pI830->overlayOn)
+	if(!pI830->overlayOn)
 	    pPriv->doubleBuffer = value;
     } else
 	return BadMatch;
@@ -2277,22 +2274,6 @@ I830PutImage(ScrnInfoPtr pScrn,
 	   drw_w, drw_h, width, height);
 #endif
 
-    if (pI830->entityPrivate) {
-	if (pI830->entityPrivate->XvInUse != -1 &&
-	    pI830->entityPrivate->XvInUse != i830_crtc_pipe (pPriv->current_crtc)) {
-#ifdef PANORAMIX
-	    if (!noPanoramiXExtension) {
-		return Success; /* faked for trying to share it */
-	    } else
-#endif
-	    {
-		return BadAlloc;
-	    }
-	}
-
-	pI830->entityPrivate->XvInUse = i830_crtc_pipe (pPriv->current_crtc);;
-    }
-
     if (!pPriv->textured) {
         /* If dst width and height are less than 1/8th the src size, the
          * src/dst scale factor becomes larger than 8 and doesn't fit in
@@ -2485,7 +2466,7 @@ I830PutImage(ScrnInfoPtr pScrn,
 #endif
 
     /* Pick the idle buffer */
-    if (!pPriv->textured && *pI830->overlayOn && pPriv->doubleBuffer)
+    if (!pPriv->textured && pI830->overlayOn && pPriv->doubleBuffer)
 	pPriv->currentBuf = !((INREG(DOVSTA) & OC_BUF) >> 20);
 
     /* copy data */
@@ -2761,9 +2742,6 @@ I830VideoBlockHandler(int i, pointer blockData, pointer pTimeout,
 
 		pPriv->videoStatus = FREE_TIMER;
 		pPriv->freeTime = now + FREE_DELAY;
-
-		if (pI830->entityPrivate)
-		    pI830->entityPrivate->XvInUse = -1;
 	    }
 	} else {				/* FREE_TIMER */
 	    if (pPriv->freeTime < now) {
@@ -2847,15 +2825,10 @@ I830StopSurface(XF86SurfacePtr surface)
     ScrnInfoPtr pScrn = surface->pScrn;
 
     if (pPriv->isOn) {
-	I830Ptr pI830 = I830PTR(pScrn);
-
 	OVERLAY_DEBUG("StopSurface\n");
 
 	i830_overlay_off (pScrn);
 
-	if (pI830->entityPrivate)
-	    pI830->entityPrivate->XvInUse = -1;
-
 	pPriv->isOn = FALSE;
     }
 
@@ -2903,22 +2876,6 @@ I830DisplaySurface(XF86SurfacePtr surface,
 
     OVERLAY_DEBUG("I830DisplaySurface\n");
 
-    if (pI830->entityPrivate) {
-	if (pI830->entityPrivate->XvInUse != -1 &&
-	    pI830->entityPrivate->XvInUse != i830_crtc_pipe (pI830Priv->current_crtc)) {
-#ifdef PANORAMIX
-	    if (!noPanoramiXExtension) {
-		return Success; /* faked for trying to share it */
-	    } else
-#endif
-	    {
-		return BadAlloc;
-	    }
-	}
-
-	pI830->entityPrivate->XvInUse = i830_crtc_pipe (pI830Priv->current_crtc);
-    }
-
     x1 = src_x;
     x2 = src_x + src_w;
     y1 = src_y;
@@ -2939,7 +2896,7 @@ I830DisplaySurface(XF86SurfacePtr surface,
     pI830Priv->YBuf1offset = pI830Priv->YBuf0offset;
 
     /* Pick the idle buffer */
-    if (!pI830Priv->textured && *pI830->overlayOn && pI830Priv->doubleBuffer) 
+    if (!pI830Priv->textured && pI830->overlayOn && pI830Priv->doubleBuffer)
 	pI830Priv->currentBuf = !((INREG(DOVSTA) & OC_BUF) >> 20);
 
     i830_display_video(pScrn, crtc, surface->id, surface->width, surface->height,
diff --git a/src/i830_xaa.c b/src/i830_xaa.c
index 7684978..1f82840 100644
--- a/src/i830_xaa.c
+++ b/src/i830_xaa.c
@@ -91,7 +91,6 @@ static void I830SubsequentScanlineImageWriteRect(ScrnInfoPtr pScrn,
 						 int skipleft);
 static void I830SubsequentImageWriteScanline(ScrnInfoPtr pScrn, int bufno);
 #endif
-static void I830RestoreAccelState(ScrnInfoPtr pScrn);
 
 void
 i830_xaa_composite(CARD8	op,
@@ -160,23 +159,10 @@ I830XAAInit(ScreenPtr pScreen)
 
     }
 
-    /* On the primary screen */
-    if (pI830->init == 0) {
-	if (pI830->xaa_scratch->size != 0) {
-	    width = ((pScrn->displayWidth + 31) & ~31) / 8;
-	    nr_buffers = pI830->xaa_scratch->size / width;
-	    ptr = pI830->FbBase + pI830->xaa_scratch->offset;
-	}
-    } else {
-	/* On the secondary screen */
-	I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-	if (pI8301->xaa_scratch_2->size != 0) {
-	    width = ((pScrn->displayWidth + 31) & ~31) / 8;
-	    nr_buffers = pI8301->xaa_scratch_2->size / width;
-	    /* We have to use the primary screen's FbBase, as that's where
-	     * we allocated xaa_scratch_2, so we get the correct pointer */
-	    ptr = pI8301->FbBase + pI8301->xaa_scratch_2->offset;
-	}
+    if (pI830->xaa_scratch->size != 0) {
+	width = ((pScrn->displayWidth + 31) & ~31) / 8;
+	nr_buffers = pI830->xaa_scratch->size / width;
+	ptr = pI830->FbBase + pI830->xaa_scratch->offset;
     }
 
     if (nr_buffers) {
@@ -223,17 +209,6 @@ I830XAAInit(ScreenPtr pScreen)
 #endif
     }
 
-    {
-	Bool shared_accel = FALSE;
-
-	for(i = 0; i < pScrn->numEntities; i++) {
-	    if(xf86IsEntityShared(pScrn->entityList[i]))
-		shared_accel = TRUE;
-	}
-	if(shared_accel == TRUE)
-	    infoPtr->RestoreAccelState = I830RestoreAccelState;
-    }
-
     /* Set up pI830->bufferOffset */
     I830SelectBuffer(pScrn, I830_SELECT_FRONT);
 
@@ -607,17 +582,8 @@ I830SubsequentColorExpandScanline(ScrnInfoPtr pScrn, int bufno)
     I830Ptr pI830 = I830PTR(pScrn);
     unsigned int tiled = I830CheckTiling(pScrn);
 
-    if (pI830->init == 0) {
-	pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
-			 pI830->FbBase);
-    } else {
-	I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-
-	/* We have to use the primary screen's FbBase, as that's where
-	 * we allocated xaa_scratch_2, so we get the correct pointer */
-	pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
-			 pI8301->FbBase);
-    }
+    pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
+		     pI830->FbBase);
 
     if (I810_DEBUG & DEBUG_VERBOSE_ACCEL)
 	ErrorF("I830SubsequentColorExpandScanline %d (addr %x)\n",
@@ -707,17 +673,8 @@ I830SubsequentImageWriteScanline(ScrnInfoPtr pScrn, int bufno)
     I830Ptr pI830 = I830PTR(pScrn);
     unsigned int tiled = I830CheckTiling(pScrn);
 
-    if (pI830->init == 0) {
-	pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
-			 pI830->FbBase);
-    } else {
-	I830Ptr pI8301 = I830PTR(pI830->entityPrivate->pScrn_1);
-
-	/* We have to use the primary screen's FbBase, as that's where
-	 * we allocated xaa_scratch_2, so we get the correct pointer */
-	pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
-			 pI8301->FbBase);
-    }
+    pI830->BR[12] = (pI830->AccelInfoRec->ScanlineColorExpandBuffers[0] -
+		     pI830->FbBase);
 
     if (I810_DEBUG & DEBUG_VERBOSE_ACCEL)
 	ErrorF("I830SubsequentImageWriteScanline %d (addr %x)\n",
@@ -870,13 +827,3 @@ fallback:
     pI830->saved_composite = ps->Composite;
     ps->Composite = i830_xaa_composite;
 }
-
-static void
-I830RestoreAccelState(ScrnInfoPtr pScrn)
-{
-#if 0
-   /* might be needed, but everything is on a ring, so I don't think so */
-   I830Sync(pScrn);
-#endif
-}
-
diff --git a/src/i915_render.c b/src/i915_render.c
index 4190808..268dd8a 100644
--- a/src/i915_render.c
+++ b/src/i915_render.c
@@ -383,7 +383,7 @@ i915_emit_composite_setup(ScrnInfoPtr pScrn)
     pI830->i915_render_state.needs_emit = FALSE;
 
     IntelEmitInvarientState(pScrn);
-    *pI830->last_3d = LAST_3D_RENDER;
+    pI830->last_3d = LAST_3D_RENDER;
 
     dst_pitch = intel_get_pixmap_pitch(pDst);
 
diff --git a/src/i915_video.c b/src/i915_video.c
index 81a0f87..93e0c86 100644
--- a/src/i915_video.c
+++ b/src/i915_video.c
@@ -76,7 +76,7 @@ I915DisplayVideoTextured(ScrnInfoPtr pScrn, I830PortPrivPtr pPriv, int id,
    intel_batch_start_atomic(pScrn, 200 + 20 * nbox);
 
    IntelEmitInvarientState(pScrn);
-   *pI830->last_3d = LAST_3D_VIDEO;
+   pI830->last_3d = LAST_3D_VIDEO;
 
    BEGIN_BATCH(20);
 
diff --git a/src/i965_render.c b/src/i965_render.c
index ab7f7d2..c123a36 100644
--- a/src/i965_render.c
+++ b/src/i965_render.c
@@ -1012,7 +1012,7 @@ i965_emit_composite_state(ScrnInfoPtr pScrn)
     render_state->needs_state_emit = FALSE;
 
     IntelEmitInvarientState(pScrn);
-    *pI830->last_3d = LAST_3D_RENDER;
+    pI830->last_3d = LAST_3D_RENDER;
 
     urb_vs_start = 0;
     urb_vs_size = URB_VS_ENTRIES * URB_VS_ENTRY_SIZE;
diff --git a/src/i965_video.c b/src/i965_video.c
index 0fc9c42..f6020d4 100644
--- a/src/i965_video.c
+++ b/src/i965_video.c
@@ -718,7 +718,7 @@ i965_emit_video_setup(ScrnInfoPtr pScrn, drm_intel_bo *bind_bo, int n_src_surf)
     int urb_cs_start, urb_cs_size;
 
     IntelEmitInvarientState(pScrn);
-    *pI830->last_3d = LAST_3D_VIDEO;
+    pI830->last_3d = LAST_3D_VIDEO;
 
     urb_vs_start = 0;
     urb_vs_size = URB_VS_ENTRIES * URB_VS_ENTRY_SIZE;
commit e9d6bbbe0b41e29c58a79844decd81771da85dd4
Author: Eric Anholt <eric at anholt.net>
Date:   Tue Mar 3 16:45:03 2009 -0800

    remove more page flipping leftovers.

diff --git a/src/i830_driver.c b/src/i830_driver.c
index f80ca69..5504025 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -305,7 +305,6 @@ typedef enum {
    OPTION_SW_CURSOR,
    OPTION_CACHE_LINES,
    OPTION_DRI,
-   OPTION_PAGEFLIP,
    OPTION_XVIDEO,
    OPTION_VIDEO_KEY,
    OPTION_COLOR_KEY,
@@ -316,7 +315,6 @@ typedef enum {
    OPTION_TILING,
    OPTION_LEGACY3D,
    OPTION_LVDSFIXEDMODE,
-   OPTION_TRIPLEBUFFER,
    OPTION_FORCEENABLEPIPEA,
 #ifdef INTEL_XVMC
    OPTION_XVMC,
@@ -2877,7 +2875,7 @@ i830_memory_init(ScrnInfoPtr pScrn)
 	}
     }
 
-    /* If tiling fails we have to disable page flipping & FBC */
+    /* If tiling fails we have to disable FBC */
     pScrn->displayWidth = savedDisplayWidth;
     if (pI830->fb_compression)
 	xf86DrvMsg(pScrn->scrnIndex, X_WARNING,


More information about the xorg-commit mailing list