diff options
author | Xiang, Haihao <[email protected]> | 2006-12-08 17:00:59 +0800 |
---|---|---|
committer | Xiang, Haihao <[email protected]> | 2006-12-08 17:00:59 +0800 |
commit | 5449f5a97524cb21194b20d05449d7211faaa51c (patch) | |
tree | 7809d2a53cfc74c90e7c90f5f63b3e0fc6335dd4 /src | |
parent | 7a10d66590a4cebd2b453218e75fe82b02a3edcc (diff) |
fix bug#9045
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_ioctl.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_ioctl.c b/src/mesa/drivers/dri/i965/intel_ioctl.c index d1f2e3f27ca..f3b76db2153 100644 --- a/src/mesa/drivers/dri/i965/intel_ioctl.c +++ b/src/mesa/drivers/dri/i965/intel_ioctl.c @@ -75,7 +75,7 @@ void intelWaitIrq( struct intel_context *intel, int seq ) { if (!intel->no_hw) { drmI830IrqWait iw; - int ret; + int ret, lastdispatch; if (0) fprintf(stderr, "%s %d\n", __FUNCTION__, seq ); @@ -83,11 +83,12 @@ void intelWaitIrq( struct intel_context *intel, int seq ) iw.irq_seq = seq; do { + lastdispatch = intel->sarea->last_dispatch; ret = drmCommandWrite( intel->driFd, DRM_I830_IRQ_WAIT, &iw, sizeof(iw) ); /* This seems quite often to return before it should!?! */ - } while (ret == -EAGAIN || ret == -EINTR || (ret == 0 && seq > intel->sarea->last_dispatch)); + } while (ret == -EAGAIN || ret == -EINTR || (ret == -EBUSY && lastdispatch != intel->sarea->last_dispatch) || (ret == 0 && seq > intel->sarea->last_dispatch)); if ( ret ) { |