diff options
author | Eric Anholt <anholt@FreeBSD.org> | 2005-08-25 03:38:07 +0000 |
---|---|---|
committer | Eric Anholt <anholt@FreeBSD.org> | 2005-08-25 03:38:07 +0000 |
commit | 61d386a93f862005d1eddb45be91c7d5421aca83 (patch) | |
tree | 3d8ab1181fd200c4212de7f3ee5323d4c4138046 /src/mesa/drivers/dri/radeon | |
parent | d545d916a838819af4ad577873aa8e590d9f5756 (diff) |
Attempt to fix the issue reported by Alan Grimes with DRM_RADEON_TEXTURE
erroring out when it shouldn't. The errno could be changed by usleep() between
the ioctl call and the loop check, if a signal was received. This could cause
an EAGAIN return from the DRM_RADEON_TEXTURE ioctl to not loop again.
Instead of checking errno, check thevalue of ret itself, since it is a saved
(and sign-flipped) copy of errno from the ioctl call.
Diffstat (limited to 'src/mesa/drivers/dri/radeon')
-rw-r--r-- | src/mesa/drivers/dri/radeon/radeon_texmem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_texmem.c b/src/mesa/drivers/dri/radeon/radeon_texmem.c index d492e190c1..3943afcde0 100644 --- a/src/mesa/drivers/dri/radeon/radeon_texmem.c +++ b/src/mesa/drivers/dri/radeon/radeon_texmem.c @@ -304,7 +304,7 @@ static void uploadSubImage( radeonContextPtr rmesa, radeonTexObjPtr t, do { ret = drmCommandWriteRead( rmesa->dri.fd, DRM_RADEON_TEXTURE, &tex, sizeof(drm_radeon_texture_t) ); - } while ( ret && errno == EAGAIN ); + } while ( ret == -EAGAIN ); UNLOCK_HARDWARE( rmesa ); |