diff options
Diffstat (limited to 'drivers/gpu/nvgpu/common/mm')
-rw-r--r-- | drivers/gpu/nvgpu/common/mm/vm.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/common/mm/vm.c b/drivers/gpu/nvgpu/common/mm/vm.c index 98bad70b..33587e5d 100644 --- a/drivers/gpu/nvgpu/common/mm/vm.c +++ b/drivers/gpu/nvgpu/common/mm/vm.c | |||
@@ -1179,9 +1179,9 @@ static int nvgpu_vm_unmap_sync_buffer(struct vm_gk20a *vm, | |||
1179 | nvgpu_mutex_release(&vm->update_gmmu_lock); | 1179 | nvgpu_mutex_release(&vm->update_gmmu_lock); |
1180 | 1180 | ||
1181 | /* | 1181 | /* |
1182 | * 500ms second timer. | 1182 | * 100ms timer. |
1183 | */ | 1183 | */ |
1184 | nvgpu_timeout_init(vm->mm->g, &timeout, 50, NVGPU_TIMER_CPU_TIMER); | 1184 | nvgpu_timeout_init(vm->mm->g, &timeout, 100, NVGPU_TIMER_CPU_TIMER); |
1185 | 1185 | ||
1186 | do { | 1186 | do { |
1187 | if (nvgpu_atomic_read(&mapped_buffer->ref.refcount) == 1) { | 1187 | if (nvgpu_atomic_read(&mapped_buffer->ref.refcount) == 1) { |
@@ -1189,9 +1189,11 @@ static int nvgpu_vm_unmap_sync_buffer(struct vm_gk20a *vm, | |||
1189 | } | 1189 | } |
1190 | nvgpu_msleep(10); | 1190 | nvgpu_msleep(10); |
1191 | } while (nvgpu_timeout_expired_msg(&timeout, | 1191 | } while (nvgpu_timeout_expired_msg(&timeout, |
1192 | "sync-unmap failed on 0x%llx") == 0); | 1192 | "sync-unmap failed on 0x%llx", |
1193 | mapped_buffer->addr) == 0); | ||
1193 | 1194 | ||
1194 | if (nvgpu_timeout_expired(&timeout)) { | 1195 | if (nvgpu_atomic_read(&mapped_buffer->ref.refcount) != 1 && |
1196 | nvgpu_timeout_expired(&timeout)) { | ||
1195 | ret = -ETIMEDOUT; | 1197 | ret = -ETIMEDOUT; |
1196 | } | 1198 | } |
1197 | 1199 | ||