summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/fence_gk20a.c
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2017-04-25 16:51:27 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-05-16 13:24:57 -0400
commit80a6291c9c5e373a3a534ba100b616b6789fb568 (patch)
tree20a5c5c3c1ea0933fa9db6af61a89c2ebd027ae0 /drivers/gpu/nvgpu/gk20a/fence_gk20a.c
parent7bc97ca7d5e0cee265014ce5fd682858c3b63629 (diff)
gpu: nvgpu: Use nvgpu_cond in semaphore wq
Change semaphore wait queue to use nvgpu_cond instead of Linux wait queue. JIRA NVGPU-14 Change-Id: I3be5097ded168300b4480e986218d9f4fd6104b1 Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: http://git-master/r/1469852 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/fence_gk20a.c')
-rw-r--r--drivers/gpu/nvgpu/gk20a/fence_gk20a.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/fence_gk20a.c b/drivers/gpu/nvgpu/gk20a/fence_gk20a.c
index 87c4f6be..3964c37d 100644
--- a/drivers/gpu/nvgpu/gk20a/fence_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/fence_gk20a.c
@@ -208,8 +208,8 @@ static int nvgpu_semaphore_fence_wait(struct gk20a_fence *f, long timeout)
208 if (!nvgpu_semaphore_is_acquired(f->semaphore)) 208 if (!nvgpu_semaphore_is_acquired(f->semaphore))
209 return 0; 209 return 0;
210 210
211 remain = wait_event_interruptible_timeout( 211 remain = NVGPU_COND_WAIT_INTERRUPTIBLE(
212 *f->semaphore_wq, 212 f->semaphore_wq,
213 !nvgpu_semaphore_is_acquired(f->semaphore), 213 !nvgpu_semaphore_is_acquired(f->semaphore),
214 timeout); 214 timeout);
215 if (remain == 0 && nvgpu_semaphore_is_acquired(f->semaphore)) 215 if (remain == 0 && nvgpu_semaphore_is_acquired(f->semaphore))
@@ -235,7 +235,7 @@ int gk20a_fence_from_semaphore(
235 struct gk20a_fence *fence_out, 235 struct gk20a_fence *fence_out,
236 struct sync_timeline *timeline, 236 struct sync_timeline *timeline,
237 struct nvgpu_semaphore *semaphore, 237 struct nvgpu_semaphore *semaphore,
238 wait_queue_head_t *semaphore_wq, 238 struct nvgpu_cond *semaphore_wq,
239 bool wfi, bool need_sync_fence) 239 bool wfi, bool need_sync_fence)
240{ 240{
241 struct gk20a_fence *f = fence_out; 241 struct gk20a_fence *f = fence_out;