]> git.baikalelectronics.ru Git - kernel.git/commit
drm/etnaviv: don't flush workqueue in etnaviv_gpu_wait_obj_inactive
authorLucas Stach <l.stach@pengutronix.de>
Fri, 17 Nov 2017 15:35:32 +0000 (16:35 +0100)
committerLucas Stach <l.stach@pengutronix.de>
Tue, 2 Jan 2018 16:17:07 +0000 (17:17 +0100)
commit1c94b3fc243a378b20ba4d5fa64813333d2d87c1
treece470f4d6cbce2bc20d05a1dfa85ce5bb46b6e66
parenta6ffac0504ccff9e18ec945468a43a8a2f5d0240
drm/etnaviv: don't flush workqueue in etnaviv_gpu_wait_obj_inactive

There is no need to synchronize with oustanding retire jobs if the object
has gone idle. Retire jobs only ever change the object state from active to
idle, not the other way around.

The IOVA put race is uncritical, as the GEM_WAIT ioctl itself is holding
a reference to the GEM object, so the retire worker will not pull the
object into the CPU domain, which is the thing we are trying to guard
against with etnaviv_gpu_wait_obj_inactive. The ordering of the various
counts and waits may change a bit, but the userspace visible behavior at
the bounds of the syscall are unchanged.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
drivers/gpu/drm/etnaviv/etnaviv_gpu.c