diff options
-rw-r--r-- | src/mesa/drivers/dri/sis/sis_context.c | 14 | ||||
-rw-r--r-- | src/mesa/drivers/dri/sis/sis_screen.c | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/sis/sis_tris.c | 1 |
3 files changed, 7 insertions, 10 deletions
diff --git a/src/mesa/drivers/dri/sis/sis_context.c b/src/mesa/drivers/dri/sis/sis_context.c index 0830e5676f..6aa6194408 100644 --- a/src/mesa/drivers/dri/sis/sis_context.c +++ b/src/mesa/drivers/dri/sis/sis_context.c @@ -84,27 +84,25 @@ static const char * const card_extensions[] = void WaitEngIdle (sisContextPtr smesa) { - GLuint cEngineState; + GLuint engineState; do { - cEngineState = MMIO_READ(REG_CommandQueue); - } while ((cEngineState & SiS_EngIdle) != SiS_EngIdle); + engineState = MMIO_READ(REG_CommandQueue); + } while ((engineState & SiS_EngIdle) != SiS_EngIdle); } void Wait2DEngIdle (sisContextPtr smesa) { - GLuint cEngineState; + GLuint engineState; do { - cEngineState = MMIO_READ(REG_CommandQueue); - } while ((cEngineState & SiS_EngIdle2d) != SiS_EngIdle2d); + engineState = MMIO_READ(REG_CommandQueue); + } while ((engineState & SiS_EngIdle2d) != SiS_EngIdle2d); } /* To be called from mWait3DCmdQueue. Separate function for profiling * purposes, and speed doesn't matter because we're spinning anyway. - * This function should use usleeps to release cpu probably, but I have yet - * to see it get called. */ void WaitingFor3dIdle(sisContextPtr smesa, int wLen) diff --git a/src/mesa/drivers/dri/sis/sis_screen.c b/src/mesa/drivers/dri/sis/sis_screen.c index 3171be5002..f1a51039d2 100644 --- a/src/mesa/drivers/dri/sis/sis_screen.c +++ b/src/mesa/drivers/dri/sis/sis_screen.c @@ -162,7 +162,7 @@ static void sisCopyBuffer( __DRIdrawablePrivate *dPriv ) ENGPACKET stEngPacket; while ((*smesa->FrameCountPtr) - MMIO_READ(0x8a2c) > SIS_MAX_FRAME_LENGTH) - usleep(1); + ; LOCK_HARDWARE(); diff --git a/src/mesa/drivers/dri/sis/sis_tris.c b/src/mesa/drivers/dri/sis/sis_tris.c index 4877e34650..abe6a3fb07 100644 --- a/src/mesa/drivers/dri/sis/sis_tris.c +++ b/src/mesa/drivers/dri/sis/sis_tris.c @@ -870,7 +870,6 @@ sisMakeRoomAGP( sisContextPtr smesa, GLint num ) sisUpdateAGP( smesa ); while (size > AGP_SpaceLeft) { /* Spin until space is available. */ - usleep(1); AGP_ReadPtr = (GLfloat *)((long)MMIO_READ(REG_3D_AGPCmBase) - (long)smesa->AGPCmdBufAddr + (long)smesa->AGPCmdBufBase); sisUpdateAGP( smesa ); |