summaryrefslogtreecommitdiff
path: root/intel
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2015-02-28 09:31:58 -0800
committerKristian Høgsberg <krh@bitplanet.net>2015-03-02 16:14:13 -0800
commit080b4929b7452dc1fea32ac1d32e7e571e7fb38b (patch)
treee7d4d3e617dade6e8dfa71c167cea535d20c67cc /intel
parentf799a527db2851b2890146a9ce777f73fea30176 (diff)
intel: Fix documentation for drm_intel_gem_bo_wait()
The kernel doesn't actually wait indefinately when passed a negative, timeout, it returns immediately. Document this and suggest using INT64_MAX for indefinite waits. Signed-off-by: Kristian Høgsberg <krh@bitplanet.net> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'intel')
-rw-r--r--intel/intel_bufmgr_gem.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/intel/intel_bufmgr_gem.c b/intel/intel_bufmgr_gem.c
index 78875fd3..33d8fbc4 100644
--- a/intel/intel_bufmgr_gem.c
+++ b/intel/intel_bufmgr_gem.c
@@ -1655,12 +1655,14 @@ drm_intel_gem_bo_wait_rendering(drm_intel_bo *bo)
*
* @bo: buffer object to wait for
* @timeout_ns: amount of time to wait in nanoseconds.
- * If value is less than 0, an infinite wait will occur.
+ * If value is less than or equal to 0, return immediately.
*
- * Returns 0 if the wait was successful ie. the last batch referencing the
- * object has completed within the allotted time. Otherwise some negative return
- * value describes the error. Of particular interest is -ETIME when the wait has
- * failed to yield the desired result.
+ * Returns 0 if the wait was successful ie. the last batch referencing
+ * the object has completed within the allotted time. Otherwise some
+ * negative return value describes the error. Of particular interest
+ * is -ETIME when the wait has failed to yield the desired result.
+ * Use a timeout of INT64_MAX to wait indefinitely (well, at least 292
+ * years).
*
* Similar to drm_intel_gem_bo_wait_rendering except a timeout parameter allows
* the operation to give up after a certain amount of time. Another subtle