diff options
| -rw-r--r-- | drivers/gpu/drm/i915/i915_gem.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index e5daad5f75fb..ac7fe39d38a3 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c | |||
| @@ -2936,9 +2936,9 @@ i915_gem_wait_ioctl(struct drm_device *dev, void *data, struct drm_file *file) | |||
| 2936 | req = obj->last_read_req; | 2936 | req = obj->last_read_req; |
| 2937 | 2937 | ||
| 2938 | /* Do this after OLR check to make sure we make forward progress polling | 2938 | /* Do this after OLR check to make sure we make forward progress polling |
| 2939 | * on this IOCTL with a timeout <=0 (like busy ioctl) | 2939 | * on this IOCTL with a timeout == 0 (like busy ioctl) |
| 2940 | */ | 2940 | */ |
| 2941 | if (args->timeout_ns <= 0) { | 2941 | if (args->timeout_ns == 0) { |
| 2942 | ret = -ETIME; | 2942 | ret = -ETIME; |
| 2943 | goto out; | 2943 | goto out; |
| 2944 | } | 2944 | } |
| @@ -2948,7 +2948,8 @@ i915_gem_wait_ioctl(struct drm_device *dev, void *data, struct drm_file *file) | |||
| 2948 | i915_gem_request_reference(req); | 2948 | i915_gem_request_reference(req); |
| 2949 | mutex_unlock(&dev->struct_mutex); | 2949 | mutex_unlock(&dev->struct_mutex); |
| 2950 | 2950 | ||
| 2951 | ret = __i915_wait_request(req, reset_counter, true, &args->timeout_ns, | 2951 | ret = __i915_wait_request(req, reset_counter, true, |
| 2952 | args->timeout_ns > 0 ? &args->timeout_ns : NULL, | ||
| 2952 | file->driver_priv); | 2953 | file->driver_priv); |
| 2953 | mutex_lock(&dev->struct_mutex); | 2954 | mutex_lock(&dev->struct_mutex); |
| 2954 | i915_gem_request_unreference(req); | 2955 | i915_gem_request_unreference(req); |
