aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu
AgeCommit message (Collapse)AuthorFilesLines
2015-08-26drm/amdgpu: fix postclose orderChristian König1-2/+2
The context needs to finish before everything else. Signed-off-by: Christian König <[email protected]> Acked-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-26drm/amdgpu: use IB for copy buffer of evictionChunming Zhou8-79/+81
This aids handling buffers moves with the scheduler. Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-26drm/amdgpu: adjust the judgement of removing fence callbackJunwei Zhang1-1/+1
The fence in the array may be skipped if wait_all is false, thus the related callback is not initialized with list head. So removing this kind callback will cause NULL pointer reference. Signed-off-by: Junwei Zhang <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-08-25drm/amdgpu: fix no sync_wait in copy_bufferChunming Zhou1-1/+7
when eviction is happening, if don't handle dependency, then the fence could be dead off. Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: fix last_vm_update fence is not effetive for sched fenceChunming Zhou4-18/+58
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: add priv data to schedChunming Zhou1-1/+2
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: add owner for sched fenceChunming Zhou3-4/+3
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: remove entity reference from sched fenceChristian König1-2/+2
Entity don't live as long as scheduler fences. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: fix and cleanup amd_sched_entity_push_jobChristian König2-2/+2
Calling schedule() is probably the worse things we can do. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: remove amdgpu_bo_list_cloneChristian König2-35/+0
Not used any more. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: remove the context from amdgpu_jobChristian König3-12/+1
Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: remove unused parameters to amd_sched_createChristian König1-3/+2
Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: fix user fences when scheduler is enabledChristian König1-0/+2
Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-25drm/amdgpu: fix fence wait in sync_fence, instead should be in sync_ringsChristian König3-3/+61
Signed-off-by: Christian König <[email protected]> Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: remove v_seq handling from the scheduler v2Christian König6-28/+11
Simply not used any more. Only keep 32bit atomic for fence sequence numbering. v2: trivial rebase Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> (v1) Reviewed-by: Jammy Zhou <[email protected]> (v1) Reviewed-by: Chunming Zhou <[email protected]> (v1)
2015-08-25drm/amdgpu: improve sa_bo->fence by kernel fenceChunming Zhou8-34/+58
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-25drm/amdgpu: modify amdgpu_fence_wait_any() to amdgpu_fence_wait_multiple()Junwei Zhang3-22/+69
Rename the function and update the related code with this modified function. Add the new parameter of bool wait_all. If wait_all is true, it will return when all fences are signaled or timeout. If wait_all is false, it will return when any fence is signaled or timeout. Signed-off-by: Junwei Zhang <[email protected]> Reviewed-by: Monk Liu <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Christian König <[email protected]>
2015-08-25drm/amdgpu: fix IH ring allocation for bus addresses (v2)Alex Deucher1-13/+7
Use pci_alloc_consistent rather than kzalloc since we need 256 byte aligned memory for the ring buffer. v2: fix copy paste typo in free function noticed by Jammy. bug: https://bugs.freedesktop.org/show_bug.cgi?id=91749 Reviewed-by: Christian König <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2015-08-21drm/amdgpu: Don't link train DisplayPort on HPD until we get the dpcdAlex Deucher1-0/+5
This is a port of: DRM - radeon: Don't link train DisplayPort on HPD until we get the dpcd to amdgpu. Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
2015-08-20drm/amdgpu: fix CS error handling v2Christian König1-41/+26
Stop double freeing the the BO list by pulling the content of amdgpu_cs_parser_prepare_job() into the IOCTL function again. v2: better commit message Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> (v1) Reviewed-by: Alex Deucher <[email protected]>
2015-08-20drm/amdgpu: fix zeroing all IB fields manually v2Christian König7-18/+6
The problem now is that we don't necessarily call amdgpu_ib_get() in some error paths and so work with uninitialized data. Better require that the memory is already zeroed. v2: better commit message Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> (v1) Reviewed-by: Alex Deucher <[email protected]>
2015-08-20drm/amdgpu: free the job immediately after dispatching itChristian König1-4/+3
Fixes a whole bunch of lockdep warnings. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-20drm/amdgpu: don't need to use bo_list_clone any moreChunming Zhou1-21/+4
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-20drm/amdgpu: some clean up for cs_ioctlChunming Zhou2-36/+1
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-20drm/amdgpu: prepare job should be common code pathChunming Zhou1-6/+4
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-20drm/amdgpu: abstract amdgpu_job for schedulerChunming Zhou7-104/+114
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-20drm/amdgpu: bump the DRM version for new allowed mem-mapped registersMarek Olšák1-1/+2
Used by mesa, etc. for profiling. Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Marek Olšák <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: wait on page directory changes. v2Bas Nieuwenhuizen3-0/+11
Pagetables can be moved and therefore the page directory update can be necessary for the current cs even if none of the the bo's are moved. In that scenario there is no fence between the sdma0 and gfx ring, so we add one. v2 (chk): rebased Signed-off-by: Bas Nieuwenhuizen <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: cleanup sheduler rq handling v2Christian König1-1/+1
Rework run queue implementation, especially remove the odd list handling. v2: cleanup the code only, no algorithem change. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-17drm/amdgpu: move prepare work out of scheduler to cs_ioctlChunming Zhou1-13/+8
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-17drm/amdgpu: fix duplicated mapping invoke bugmonk.liu1-0/+1
fix the bug that there is duplicated bo_update_mapping issued Signed-off-by: monk.liu <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]>
2015-08-17drm/amdgpu: drop bo_list_clone when no schedulermonk.liu1-9/+13
bo_list_clone() will take a lot of time when bo_list hold too much elements, like above 7000 Signed-off-by: Monk.Liu <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-08-17drm/amdgpu: disable GPU reset by defaultAlex Deucher1-2/+2
It's not validated yet and causes more harm than good. Avoids spurious resets. Reviewed-by: Leo Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: fix type mismatch errormonk.liu1-2/+3
remaining timeout returned by amdgpu_fence_wait_any can be larger than max int value, thus the truncated 32 bit value in r ends up being negative while its original long value is positive. Signed-off-by: monk.liu <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
2015-08-17drm/amdgpu: add reference for **fenceChunming Zhou10-3/+14
fix fence is released when pass to **fence sometimes. add reference for it. Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-17drm/amdgpu: fix waiting for all fences before flippingChristian König2-29/+56
Otherwise we might see corruption. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: fix UVD return code checkingChristian König1-5/+5
Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Tested-and-Reviewed-by: Leo Liu <[email protected]>
2015-08-17drm/amdgpu: remove amd_sched_wait_emit v2Christian König1-2/+0
Not used any more. v2: remove amd_sched_emit as well. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]>
2015-08-17drm/amdgpu: don't grab dev->struct_mutex in pm functionsDaniel Vetter1-2/+0
Similar to radeon, except that amdgpu doesn't even use struct_mutex to protect anything like the shared z buffer (sane gpu architecture, yay!). And the code already grabs the globa adev->ring_lock, so this code can't race with itself. Which makes struct_mutex completely redundnant. Remove it. Cc: Alex Deucher <[email protected]> Cc: "Christian König" <[email protected]> Reviewed-by: Thierry Reding <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: Don't take dev->struct_mutex in bo_force_deleteDaniel Vetter1-3/+1
It really doesn't protect anything which doesn't have other locks already. Also this is run from driver unload code so not much need for locks anyway. Same changes as for radeon really. Cc: Alex Deucher <[email protected]> Cc: "Christian König" <[email protected]> Reviewed-by: Thierry Reding <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: remove VI hw bug workaround v3Christian König2-13/+1
The workaround simply doesn't work because VM mappings are controlled by userspace not the kernel. Additional to that this is just a performance problem which happens if you have holes in your VM mapping. v2: adjust virtual addr alignment as well. v3: fix trivial warning Signed-off-by: Christian König <[email protected]> Reviewed-by: Monk Liu <[email protected]> (v1) Reviewed-by: Jammy Zhou <[email protected]> (v2)
2015-08-17drm/amdgpu: cleanup amdgpu_fence_ring_wait_seqChristian König1-69/+15
Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: remove duplicate amdgpu_fence_process implementationChristian König1-58/+1
Looks like that somehow got missed while during porting the radeon changes. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: remove amdgpu_fence_waitChristian König6-30/+7
It was just a wrapper for fence_wait anyway. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: use the reservation obj wait for the UVD msgChristian König1-8/+5
Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amdgpu: remove amdgpu_fence_signaledChristian König3-26/+4
The common kernel function does the same thing. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
2015-08-17drm/amd: add scheduler fence implementation (v2)Chunming Zhou6-34/+35
scheduler fence is based on kernel fence framework. v2: squash in Christian's build fix Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-17drm/amdgpu: use kernel submit helper in vmChunming Zhou3-144/+33
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-17drm/amdgpu: use amd_sched_job in its backend opsChunming Zhou1-17/+17
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian K?nig <[email protected]>
2015-08-17drm/amdgpu: cleanup and fix scheduler fence handling v2Christian König1-18/+8
v2: rebased Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> (v1) Reviewed-by: Chunming Zhou <[email protected]>