]> git.baikalelectronics.ru Git - kernel.git/commit
drm/tegra: dc: Request/free syncpoint at init/exit
authorThierry Reding <treding@nvidia.com>
Mon, 24 Aug 2015 12:47:10 +0000 (14:47 +0200)
committerThierry Reding <treding@nvidia.com>
Fri, 30 Oct 2015 17:40:52 +0000 (18:40 +0100)
commit1e69c36c5f53ed41bc57f909d4f2c5bf6ab0a7cb
tree4725c0bc83dc24e65c09d00a79f1521623a8e2d5
parenta9180c2015a401633782e12f714a95a6d04d2437
drm/tegra: dc: Request/free syncpoint at init/exit

syncpoints are resources provided by host1x and their lifetime is tied
to the host1x device. They are not properly reference counted either, so
removing the host1x device before any of its clients causes a use-after-
free error. Adding proper reference counting would be a major enterprise
so work around it for now by requesting and freeing the syncpoint at
init and exit time, respectively. The host1x device is guaranteed to be
around at this point.

Signed-off-by: Thierry Reding <treding@nvidia.com>
drivers/gpu/drm/tegra/dc.c