intel: Retry pin ioctl on -EINTR.

main
Eric Anholt 2009-01-04 17:37:18 -08:00
parent 65b90fb377
commit 02445eab64
1 changed files with 4 additions and 1 deletions

View File

@ -999,7 +999,10 @@ drm_intel_gem_bo_pin(drm_intel_bo *bo, uint32_t alignment)
pin.handle = bo_gem->gem_handle;
pin.alignment = alignment;
ret = ioctl(bufmgr_gem->fd, DRM_IOCTL_I915_GEM_PIN, &pin);
do {
ret = ioctl(bufmgr_gem->fd, DRM_IOCTL_I915_GEM_PIN, &pin);
} while (ret == -1 && errno == EINTR);
if (ret != 0)
return -errno;