diff options
author | Christian König <christian.koenig@amd.com> | 2018-02-04 04:32:35 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2018-02-19 14:20:18 -0500 |
commit | c633c00bf06779ec6d5e2c01748d4753ede98f8a (patch) | |
tree | 012bb3f787d03d71b7c13d16e7bf483d20ff6828 /drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |
parent | ec47734a6d0e82c132e3e0883f2f663f138da43a (diff) |
drm/amdgpu: separate PASID mapping from VM flush v2
Stuffing the PASID mapping into the VM flush isn't flexible enough since
the PASID mapping changes not as often as we need a VM flush.
v2: add missing use of gmc_v7_0_emit_pasid_mapping
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 0572d6072baa..afa16a862eaa 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | |||
@@ -612,8 +612,11 @@ int amdgpu_vm_flush(struct amdgpu_ring *ring, struct amdgpu_job *job, bool need_ | |||
612 | struct dma_fence *fence; | 612 | struct dma_fence *fence; |
613 | 613 | ||
614 | trace_amdgpu_vm_flush(ring, job->vmid, job->vm_pd_addr); | 614 | trace_amdgpu_vm_flush(ring, job->vmid, job->vm_pd_addr); |
615 | amdgpu_ring_emit_vm_flush(ring, job->vmid, job->pasid, | 615 | amdgpu_ring_emit_vm_flush(ring, job->vmid, job->vm_pd_addr); |
616 | job->vm_pd_addr); | 616 | if (adev->gmc.gmc_funcs->emit_pasid_mapping && |
617 | ring->funcs->emit_wreg) | ||
618 | amdgpu_gmc_emit_pasid_mapping(ring, job->vmid, | ||
619 | job->pasid); | ||
617 | 620 | ||
618 | r = amdgpu_fence_emit(ring, &fence); | 621 | r = amdgpu_fence_emit(ring, &fence); |
619 | if (r) | 622 | if (r) |