aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu
AgeCommit message (Collapse)AuthorFilesLines
2017-12-15drm/amdgpu: set allow_reserved_eviction and resv when bo allocation and csRoger He2-2/+12
enable eviction of other per VM BOs during allocation and allows reaping of deleted BOs during CS. Reviewed-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Roger He <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-14drm/amdgpu: add enumerate for PDB/PTB v3Chunming Zhou2-19/+61
v2: remove SUBPTB member v3: remove last_level, use AMDGPU_VM_PTB directly instead. Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: fix huge page setting for ATS caseChunming Zhou1-1/+1
Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: drop amdgpu_atombios_scratch_regs_save/restoreAlex Deucher2-24/+0
No longer used. Reviewed-by: Harry Wentland <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: drop scratch regs save and restore from GPU reset handlingAlex Deucher1-2/+0
The expectation is that the base driver doesn't mess with these. Some components interact with these directly so let the components handle these directly. Reviewed-by: Harry Wentland <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: drop scratch regs save and restore from S3/S4 handlingAlex Deucher1-2/+0
The expectation is that the base driver doesn't mess with these. Some components interact with these directly so let the components handle these directly. Reviewed-by: Harry Wentland <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: remove some old gc 9.x registersAlex Deucher1-4/+4
Leftover from bring up. Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: drop soc15_init_golden_registersAlex Deucher1-31/+0
The golden register arrays were empty so the function was effectively useless. Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: drop the bios scratch reg callbacks from nbioAlex Deucher3-31/+0
They are not used any longer. We get the scratch register locations from the vbios directly now. Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-13drm/amdgpu: convert nbio to use callbacks (v2)Alex Deucher11-183/+209
Cleans up and consolidates all of the per-asic logic. v2: squash in "drm/amdgpu: fix NULL err for sriov detect" (Chunming) Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: make function names consistent in nbio filesAlex Deucher2-16/+16
All functions should have nbio_v* prefix. Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: correct vce fw data and stack sizeFrank Min1-1/+1
this fix the VCE world switch hang issue Signed-off-by: Frank Min <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: fix MAP_QUEUES paramterMonk Liu1-1/+1
Should be 0. Signed-off-by: Monk Liu <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: no need with INT for fence pollingMonk Liu1-1/+1
We are polling so no need for INT. Signed-off-by: Monk Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: no need to evict VRAM in device_finiMonk Liu1-2/+1
this VRAM evict is not needed and also cost 2seconds to finish because the IRQ is software side disabled before it. Signed-off-by: Monk Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: allow get_vm_pde to change flags as wellChristian König11-38/+54
And also provide the level for which we need a PDE. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: batch PDE updates againChristian König1-109/+94
Now instead of one submission for each PDE batch them together over all PDs who need an update. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: remove keeping the addr of the VM PDsChristian König2-10/+5
No more double house keeping. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: remove last_entry_used from the VM codeChristian König2-24/+29
Not needed any more. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: avoid the modulo in amdgpu_vm_get_entryChristian König1-3/+3
We can do this with a simple mask as well. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: use polling mem to set SDMA3 wptr for VFPixel Ding2-8/+20
On Tonga VF, there're 2 sources updating wptr registers for sdma3: 1) polling mem and 2) doorbell. When doorbell and polling mem are both enabled on sdma3, there will be collision hit in occasion between those two sources when ucode and h/w are doing the updating on wptr register in parallel. Issue doesn't happen on CP GFX/Compute since CP drops all doorbell writes when VF is inactive. So enable polling mem and don't use doorbell for SDMA3. Signed-off-by: Pixel Ding <[email protected]> Reviewed-by: Monk Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: update one PDE at a time v2Christian König1-46/+34
Horrible inefficient, but avoids problems when the root PD size becomes to big. v2: remove incr as well. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: stop joining PDEsChristian König1-34/+7
That doesn't hit any more most of the time anyway. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: add amdgpu_evict_vram debugfs fileChristian König1-1/+12
Torture test for MM and VM support, can be used to evict all VRAM while the system is under load. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-12drm/amdgpu: cleanup debugfs handling a bitChristian König3-43/+11
Remove the superflous .debugfs_init callback and register all files in amdgpu_device.c in just one function. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-08drm/admgpu: Reduce the usage of soc15ip.hShaoyun Liu16-17/+0
Remove the header where it's not used. Acked-by: Christian Konig <[email protected]> Signed-off-by: Shaoyun Liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-08drm/amdgpu: Change SOC15_REG_OFFSET to use dynamic register offsetShaoyun Liu8-18/+46
Acked-by: Christian Konig <[email protected]> Signed-off-by: Shaoyun Liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-08drm/amdgpu: Avoid use SOC15_REG_OFFSET in static const arrayShaoyun Liu13-283/+354
Handle dynamic offsets correctly in static arrays. Acked-by: Christian Konig <[email protected]> Signed-off-by: Shaoyun Liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-08drm/amdgpu: Use dynamic IP offset for register access on SOC15Shaoyun Liu2-95/+65
Update the register access macros and functions to take into account the new dynamic IP base offsets. Acked-by: Christian Konig <[email protected]> Signed-off-by: Shaoyun Liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-08drm/amdgpu: Dynamic initialize IP base offsetShaoyun Liu5-1/+96
The base offsets of the IP blocks may change across asics even though the relative register offsets are the same for an IP. Handle this dynamically. Acked-by: Christian Konig <[email protected]> Signed-off-by: Shaoyun Liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-07drm/sched: move fence slab handling to module init/exitLucas Stach1-8/+0
This is the only part of the scheduler which must not be called from different drivers. Move it to module init/exit so it is done a single time when loading the scheduler. Reviewed-by: Chunming Zhou <[email protected]> Tested-by: Dieter Nützel <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Lucas Stach <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-07drm: move amd_gpu_scheduler into common locationLucas Stach26-121/+119
This moves and renames the AMDGPU scheduler to a common location in DRM in order to facilitate re-use by other drivers. This is mostly a straight forward rename with no code changes. One notable exception is the function to_drm_sched_fence(), which is no longer a inline header function to avoid the need to export the drm_sched_fence_ops_scheduled and drm_sched_fence_ops_finished structures. Reviewed-by: Chunming Zhou <[email protected]> Tested-by: Dieter Nützel <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Lucas Stach <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-07drm/amdgpu: add license to files where it was missingAlex Deucher2-1/+25
These files were missing it before. Acked-by: Harry Wentland <[email protected]> Acked-by: Felix Kuehling <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-07drm/amdgpu: add license to MakefilesAlex Deucher1-1/+21
Was missing license text. Acked-by: Harry Wentland <[email protected]> Acked-by: Felix Kuehling <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-07drm/amdgpu: Fix amdgpu_sync_add_later to preserve explicit flag.Andrey Grodzovsky1-3/+6
Signed-off-by: Andrey Grodzovsky <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: Use drm_fb_helper_lastclose() and _poll_changed()Noralf Trønnes5-42/+3
This driver can use drm_fb_helper_lastclose() in its .lastclose function. It can also use drm_fb_helper_output_poll_changed() as its .output_poll_changed callback. Remove the unused driver implementations. Cc: Alex Deucher <[email protected]> Cc: "Christian König" <[email protected]> Signed-off-by: Noralf Trønnes <[email protected]> Acked-by: Daniel Vetter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: fix amdgpu_sync_resv v2Christian König1-5/+2
Fixes a bug introduced by AMDGPU_GEM_CREATE_EXPLICIT_SYNC. We still need to wait for pipelined moves in the shared fences list. v2: fix typo Signed-off-by: Christian König <[email protected]> Reviewed-by: Andres Rodriguez <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amd/amdgpu: set gtt size according to system memory size onlyRoger He1-5/+3
Reviewed-by: Christian König <[email protected]> Signed-off-by: Roger He <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: Get rid of dep_sync as a seperate object.Andrey Grodzovsky7-35/+37
Instead mark fence as explicit in it's amdgpu_sync_entry. v2: Fix use after free bug and add new parameter description. Signed-off-by: Andrey Grodzovsky <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: allow specifying vm_block_size for multi level PDs v2Christian König2-19/+10
This patch allows specifying the vm_block_size even when multi level page directories are active. v2: fix signed/unsigned compare warning Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: move validation of the VM size into the VM codeChristian König7-24/+20
This moves validation of the VM size parameter into amdgpu_vm_adjust_size(). Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: allow non pot VM size valuesChristian König1-6/+0
The VM size actually doesn't need to be a power of two. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: choose number of VM levels based on VM sizeChristian König1-5/+11
This allows us limiting the VM size for testing even of Vega10. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: unify VM size handling of Vega10 with older generationChristian König6-47/+22
One function to rule them all. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: fix amdgpu_vm_num_entriesChristian König1-7/+7
The block size only affects the leave nodes, everything else is fixed. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: fix VM PD addr shiftChristian König1-5/+23
The block size only affects the leave nodes, everything else is fixed. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amdgpu: correct vce4.0 fw config for SRIOV (V2)Frank Min1-13/+25
1. program vce 4.0 fw with 48 bit address 2. correct vce 4.0 fw stack and date offset Acked-by: Christian König <[email protected]> Signed-off-by: Frank Min <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amd/include:cleanup raven1 vcn header files.Feifei Xu2-3/+3
Cleanup asic_reg/raven1/VCN folder. Remove unused vcn_1_0_default.h. Signed-off-by: Feifei Xu <[email protected]> Acked-by: Christian König <[email protected]> Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amd/include:cleanup raven1 nbio header files.Feifei Xu1-3/+3
Cleanup asic_reg/raven1/NBIO folder. Signed-off-by: Feifei Xu <[email protected]> Acked-by: Christian König <[email protected]> Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-12-06drm/amd/include:cleanup raven1 mp header files.Feifei Xu1-1/+1
Cleanup asic_reg/raven1/MP folder. Signed-off-by: Feifei Xu <[email protected]> Acked-by: Christian König <[email protected]> Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>