summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common/linux/os_fence_android.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/common/linux/os_fence_android.c')
-rw-r--r--drivers/gpu/nvgpu/common/linux/os_fence_android.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/os_fence_android.c b/drivers/gpu/nvgpu/common/linux/os_fence_android.c
index d689a2a8..d8f70639 100644
--- a/drivers/gpu/nvgpu/common/linux/os_fence_android.c
+++ b/drivers/gpu/nvgpu/common/linux/os_fence_android.c
@@ -55,15 +55,15 @@ void nvgpu_os_fence_android_drop_ref(struct nvgpu_os_fence *s)
55int nvgpu_os_fence_fdget(struct nvgpu_os_fence *fence_out, 55int nvgpu_os_fence_fdget(struct nvgpu_os_fence *fence_out,
56 struct channel_gk20a *c, int fd) 56 struct channel_gk20a *c, int fd)
57{ 57{
58 int err; 58 int err = -ENOSYS;
59 59
60 err = nvgpu_os_fence_sema_fdget(fence_out, c, fd); 60#ifdef CONFIG_TEGRA_GK20A_NVHOST
61 err = nvgpu_os_fence_syncpt_fdget(fence_out, c, fd);
62#endif
63
64 if (err)
65 err = nvgpu_os_fence_sema_fdget(fence_out, c, fd);
61 66
62 /* TO-DO
63 * check if fence is empty and if CONFIG_TEGRA_GK20A_NVHOST
64 * is enabled, try to get a sync_fence using
65 * corresponding nvhost method.
66 */
67 if (err) 67 if (err)
68 nvgpu_err(c->g, "error obtaining fence from fd %d", fd); 68 nvgpu_err(c->g, "error obtaining fence from fd %d", fd);
69 69