Skip to content

Commit

Permalink
drm/lima: fix MMU page fault when onscreen kmscube
Browse files Browse the repository at this point in the history
Signed-off-by: Qiang Yu <yuq825@gmail.com>
  • Loading branch information
yuq committed Nov 25, 2017
1 parent 60f7334 commit a826702
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion drivers/gpu/drm/lima/lima_mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,15 @@ void lima_mmu_switch_vm(struct lima_mmu *mmu, struct lima_vm *vm, bool reset)
if (mmu->vm == vm) {
if (reset)
vm = dev->empty_vm;
else if (!mmu->zap_all)
else {
/* TODO: mmu->zap_all was designed here when active VM is
* updated, zap the MMU TLB. But seems we need always do zap
* (without stall) before start task with the same VM. So
* the MMU TLB can't keep across tasks with the same VM?
*/
mmu_write(COMMAND, LIMA_MMU_COMMAND_ZAP_CACHE);
goto out;
}
}

lima_mmu_send_command(LIMA_MMU_COMMAND_ENABLE_STALL,
Expand Down

0 comments on commit a826702

Please sign in to comment.