--- xserver-xorg-video-intel-2.2.0.orig/src/i830_driver.c 2007-11-15 13:02:59.000000000 -0500 +++ xserver-xorg-video-intel-2.2.0/src/i830_driver.c 2007-12-27 10:49:37.000000000 -0500 @@ -2980,6 +2980,8 @@ ScrnInfoPtr pScrn = xf86Screens[scrnIndex]; I830Ptr pI830 = I830PTR(pScrn); + ErrorF("I830LeaveVT() 0.0\n"); + DPRINTF(PFX, "Leave VT\n"); pI830->leaving = TRUE; @@ -2988,6 +2990,8 @@ TimerCancel(pI830->devicesTimer); pI830->devicesTimer = NULL; + ErrorF("I830LeaveVT() 1.0\n"); + i830SetHotkeyControl(pScrn, HOTKEY_BIOS_SWITCH); if (!I830IsPrimary(pScrn)) { @@ -2997,6 +3001,8 @@ } } + ErrorF("I830LeaveVT() 2.0\n"); + #ifdef XF86DRI if (pI830->directRenderingOpen) { DRILock(screenInfo.screens[pScrn->scrnIndex], 0); @@ -3006,20 +3012,32 @@ } #endif + ErrorF("I830LeaveVT() 3.0\n"); + xf86_hide_cursors (pScrn); + ErrorF("I830LeaveVT() 4.0\n"); + RestoreHWState(pScrn); + ErrorF("I830LeaveVT() 5.0\n"); + i830_stop_ring(pScrn, TRUE); + ErrorF("I830LeaveVT() 6.0\n"); + if (pI830->debug_modes) { i830CompareRegsToSnapshot(pScrn, "After LeaveVT"); i830DumpRegs (pScrn); } + ErrorF("I830LeaveVT() 7.0\n"); + if (I830IsPrimary(pScrn)) i830_unbind_all_memory(pScrn); + ErrorF("I830LeaveVT() 8.0\n"); + /* Tell the kernel to evict all buffer objects and block new buffer * allocations until we relese the lock. */ @@ -3031,8 +3049,12 @@ } #endif /* XF86DRI_MM */ + ErrorF("I830LeaveVT() 9.0\n"); + if (pI830->AccelInfoRec) pI830->AccelInfoRec->NeedToSync = FALSE; + + ErrorF("I830LeaveVT() 10.0\n"); } /*