static void TridentClearSync(ScrnInfoPtr pScrn) { TRIDENTPtr pTrident = TRIDENTPTR(pScrn); int count = 0, timeout = 0; int busy; for (;;) { BLTBUSY(busy); if (busy != GE_BUSY) { return; } count++; if (count == 10000000) { ErrorF("Trident: BitBLT engine time-out.\n"); count = 9990000; timeout++; if (timeout == 8) { /* Reset BitBLT Engine */ TGUI_STATUS(0x00); return; } } } }
static void XPSync(ScrnInfoPtr pScrn) { TRIDENTPtr pTrident = TRIDENTPTR(pScrn); int count = 0, timeout = 0; int busy; BLADE_XP_OPERMODE(pTrident->EngineOperation); for (;;) { BLTBUSY(busy); if (busy != GE_BUSY) { return; } count++; if (count == 10000000) { ErrorF("XP: BitBLT engine time-out.\n"); count = 9990000; timeout++; if (timeout == 8) { /* Reset BitBLT Engine */ TGUI_STATUS(0x00); return; } } } }