Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Snippets Groups Projects
Commit e60a0b10 authored by Chris Wilson's avatar Chris Wilson
Browse files

drm/i915: Sleep whilst waiting for the ring


If userspace is submitting so many long running batches that the ring
becomes full, throttle by sleeping for a 1ms before checking for free
space. Simply yielding was causing excessive scheduler overhead whilst
making no progress.

Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
parent 7b5337dd
Branches
No related tags found
No related merge requests found
...@@ -707,7 +707,7 @@ int intel_wait_ring_buffer(struct drm_device *dev, ...@@ -707,7 +707,7 @@ int intel_wait_ring_buffer(struct drm_device *dev,
master_priv->sarea_priv->perf_boxes |= I915_BOX_WAIT; master_priv->sarea_priv->perf_boxes |= I915_BOX_WAIT;
} }
yield(); msleep(1);
} while (!time_after(jiffies, end)); } while (!time_after(jiffies, end));
trace_i915_ring_wait_end (dev); trace_i915_ring_wait_end (dev);
return -EBUSY; return -EBUSY;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment