summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/vgpu/fifo_vgpu.c')
-rw-r--r--drivers/gpu/nvgpu/vgpu/fifo_vgpu.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c b/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c
index 5ffc6a00..e9a2d582 100644
--- a/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c
+++ b/drivers/gpu/nvgpu/vgpu/fifo_vgpu.c
@@ -678,17 +678,20 @@ static int vgpu_fifo_force_reset_ch(struct channel_gk20a *ch,
678static void vgpu_fifo_set_ctx_mmu_error(struct gk20a *g, 678static void vgpu_fifo_set_ctx_mmu_error(struct gk20a *g,
679 struct channel_gk20a *ch) 679 struct channel_gk20a *ch)
680{ 680{
681 if (ch->error_notifier) { 681 mutex_lock(&ch->error_notifier_mutex);
682 if (ch->error_notifier_ref) {
682 if (ch->error_notifier->status == 0xffff) { 683 if (ch->error_notifier->status == 0xffff) {
683 /* If error code is already set, this mmu fault 684 /* If error code is already set, this mmu fault
684 * was triggered as part of recovery from other 685 * was triggered as part of recovery from other
685 * error condition. 686 * error condition.
686 * Don't overwrite error flag. */ 687 * Don't overwrite error flag. */
687 } else { 688 } else {
688 gk20a_set_error_notifier(ch, 689 gk20a_set_error_notifier_locked(ch,
689 NVGPU_CHANNEL_FIFO_ERROR_MMU_ERR_FLT); 690 NVGPU_CHANNEL_FIFO_ERROR_MMU_ERR_FLT);
690 } 691 }
691 } 692 }
693 mutex_unlock(&ch->error_notifier_mutex);
694
692 /* mark channel as faulted */ 695 /* mark channel as faulted */
693 ch->has_timedout = true; 696 ch->has_timedout = true;
694 wmb(); 697 wmb();