drm/i915: Inifite timeout for wait ioctl
authorBen Widawsky <ben@bwidawsk.net>
Tue, 5 Jun 2012 22:24:24 +0000 (15:24 -0700)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 6 Jun 2012 10:25:46 +0000 (12:25 +0200)
commiteac1f14fd1e7243aa782ef85f2a217e0c3a709ad
treea6078850f0479ccc9c5f18a52b8fec5897e843be
parentde9a35abb3b343a25065449234e47a76c4f3454a
drm/i915: Inifite timeout for wait ioctl

Change the ns_timeout parameter of the wait ioctl to a signed value.
Doing this allows the kernel to provide an infinite wait when a timeout
of less than 0 is provided. This mimics select/poll.

Initially the parameter was meant to match up with the GL spec 1:1, but
after being made aware of how much 2^64 - 1 nanoseconds actually is, I
do not think anyone will ever notice the loss of 1 bit.

The infinite timeout on waiting is similar to the existing i915
userspace interface with the exception that struct_mutex is dropped
while doing the wait in this ioctl.

Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem.c
include/drm/i915_drm.h
This page took 0.026586 seconds and 5 git commands to generate.